Skip to content

nixCraft

Linux and Unix tutorials for new and seasoned sysadmin

  • Home
  • About
  • Linux Shell Scripting TutoriaL
  • RSS/Feed
  • Donations
  • Search

nixCraft

Linux and Unix tutorials for new and seasoned sysadmin

nixCraft

BASH Shell

BASH Shell and Scripting Frequently Asked Questions, Help, Hacks, Tips and more

How to return pid of a last command in Linux / Unix

last updated November 19, 2019 in Categories BASH Shell, Linux, UNIX

I need to find and return the PID of the last command executed in Linux. How do I return the PID of command in Linux?

1 Comment

Bash get filename from given path on Linux or Unix

last updated November 14, 2019 in Categories BASH Shell, Linux, Mac OS X, UNIX

How do I extract filename and extension in the Bash shell script from the given path? How can I get filename from the path under the bash shell?

0 Comments

How to find a website’s DNS (name server) address

last updated November 3, 2019 in Categories BASH Shell, Linux, UNIX, Windows

How can I find a website’s DNS address? How do I check the current DNS servers of a domain or website using a Linux or macOS command line option? How do I find DNS address of a website using bash?

1 Comment

How to find Public IP address AWS EC2 or Lightsail VM

last updated October 21, 2019 in Categories Amazon Cloud Computing, BASH Shell, Linux, UNIX

I need to get public IPv4 address on current EC2 or Lightsail VM Linux/Unix instance. How do I find Public IP address AWS EC2 or Lightsail VM?

8 Comments

Change default shell to bash on Macos Catalina

last updated October 8, 2019 in Categories BASH Shell, Mac OS X, UNIX

I noticed that my default shell set to zsh on Macos Catalina. How do I change my default shell to bash on Macos Catalina using the command line or GUI options?

1 Comment

Linux run a command with a time limit (timeout)

last updated September 26, 2019 in Categories BASH Shell, CentOS, Debian / Ubuntu, Linux, Programming, RedHat and Friends, Suse, UNIX

I want to start command called foo, and kill it if still running after given DURATION in seconds. How do I run a command a time Limit on Linux? How do I run a Linux command, and have it timeout (abort) after N seconds?

1 Comment

How do I force delete a directory in Linux?

last updated July 5, 2019 in Categories BASH Shell, CentOS, Debian / Ubuntu, Linux, RedHat and Friends, Suse

I am trying to delete a directory in Linux using the rmdir dir1 command. But, I am getting an error that read as follows:
rmdir: failed to remove `dir1': Directory not empty
How do I force remove and delete a directory in Linux?

1 Comment

Posts navigation

Page 1 Page 2 … Page 104 Next page

Cool Linux penguin shirt

FEATURED ARTICLES

  • 1
    30 Cool Open Source Software I Discovered in 2013
  • 2
    30 Handy Bash Shell Aliases For Linux / Unix / Mac OS X
  • 3
    Top 32 Nmap Command Examples For Linux Sys/Network Admins
  • 4
    25 PHP Security Best Practices For Linux Sys Admins
  • 5
    30 Linux System Monitoring Tools Every SysAdmin Should Know
  • 6
    40 Linux Server Hardening Security Tips
  • 7
    Linux: 25 Iptables Netfilter Firewall Examples For New SysAdmins
  • 8
    Top 20 OpenSSH Server Best Security Practices
  • 9
    Top 25 Nginx Web Server Best Security Practices
  • 10
    My 10 UNIX Command Line Mistakes

Sign up for my newsletter

Sign up for my newsletter



RSS Recently updated

  • Vi / Vim Save And Quit The Editor Command
  • Understanding /etc/passwd File Format
  • How to install and use Nginx on OpenSUSE Linux server
  • Debian / Ubuntu Linux Delete Old Kernel Images Command
  • How to generate RSS 2.0 feed quickly using Python
  • [How to] Linux Change or Rename User Name and UID
  • Bash Assign Output of Shell Command To Variable
  • Bash check if process is running or not on Linux / Unix
  • FreeBSD Find Out All Installed Hard Disk Size Information
  • How to delete empty lines using sed command under Linux / UNIX

Corporate Patron

  • Linode
  • Cloudflare
  • Prospect One
nixCraft ©2000-2019 nixCraft. All rights reserved.
  • PRIVACY
  • TERM OF SERVICE
  • CONTACT/EMAIL
  • DONATIONS
  • Search