To perform disk usage monitoring of users on a UNIX system, you will, first of all, need to determine the home directories of the users. You might ask, “Aren’t all the user home directories found under /home?”. Well, typically yes, but it’s not always true.
Netcat is often known as the swiff army knife for TCP/IP. It’s features include but not limited to UDP/TCP port scanning, file transfers, tunneling of UDP over TCP, port forwarding and so on.
A couple of readers, upon reading this article to calculate yesterday’s date in a shell script, have requested for a similar script that can be used to calculate tomorrow’s date.
August 1st, 2009 | | Tags:
blowfish,
crypt,
des,
hash,
linux,
md5,
password,
sha,
shadow,
unix
In modern UNIX and Linux systems, user passwords are encrypted and stored in the /etc/shadow file. On BSD systems, the passwords are kept in the /etc/master.passwd file. The encrypted password field in the file contains more than just the encrypted password, it contains additional information.
There are times when you will need to calculate yesterday’s date in a UNIX shell script to run some date sensitive cron jobs. There are currently no standard command line tools in UNIX to perform such date arithmetic.
June 20th, 2009 | | Tags:
account,
expired,
linux,
locked,
root,
setuid,
solaris,
suroot,
unix,
unlock
If your organisation has password aging policy set for your UNIX servers, there is a possibility that the root account may also get locked out due to the existence of an expiry date set in the /etc/shadow file. Once the root account is locked, all jobs (cron, etc) that require root privileges may start to fail. To unlock the root account on a SUN SPARC machine, you will need to:
The default command line ftp client in most UNIX distributions do not support recursive downloads, even though recursive downloads is a basic feature in most GUI based ftp clients. But if you do not have access to the X-Windows or GUI, there are alternative ways to achieve the same result from the command line.
Have you ever encountered the dreaded “Connection closed by foreign host” message when you were logged into a remote server via SSH and you were in the middle of some important task? You have most probably just lost your session and you will have to start your task all over again. Well, you can prevent this from happening by using the screen command available in most UNIX and Linux distributions.
Solaris, by default, loads a 64-bit kernel during boot up, if the hardware supports it.
If, for whatever reason, you need to load Solaris in 32-bit mode, the following commands can be used to switch between the 32-bit and 64-bit kernels.
Ubuntu Linux distribution, by default, disables the root account. To run a command with root privileges, sudo has to be used before the command.