Basic Unix Commands Required For Sap Administration
Basic Unix Commands Required For Sap Administration
pwd
to know present working directory.
ps –ef
to know all processes.
kill pid
to kill particular process.
kill –9 pid
to kill process forcefully.
vi filename
to edit file in vi.
ls filename
Lists all files and directories.
ls –l
it gives full information of files and directories.
ls –a
it displays hidden files
ls –p
shows difference b/w files and directories.
ls –i
Displys inode no of files and directories.
File permissions
Numeric mode
To assign permissions
To remove permissions
Network communication
telnet ipaddress
it connets to remote system
ftp ipaddress
scp /dir ipaddress:/dir
it copies date from source system to target system
ssh ipaddress:mkdir /dir
it executes commands in remote system.
Only in homogenous environment
rlogin ipaddress
User commads
who
displays all users who are currently logged in system.
who am I
displays detailed information about current logged in user.
last
displays information about when system is lastly rebooted,who,time.
finger
information about current logged in user.
filesystems
df
it displays all filesystems with sizes
df –h
it displays all filesystems with human readable form.
shutdown
init 0
like shutdown
init 1
single user mode
init 6
like reboot
reboot
poweroff
copy or move
To copy a file
cp sourcefile targetfile
To copy empty directory
cp sourcedir targetdir
To copy directory with all contents
cp –r sourcedir targetdir
To move file
mv sourcefile targetfile
To move directory
mv sourcdir targetdir
creating links
find
type options:
d directory
f regular file
l symbolic link
for searched files in range( from more than 64 days old to 95 days old)
find . -name "*" -a "(" -mtime +64 -a -mtime -95 ")" -exec ll {} \;
to know files in current directory which are more than 10M size.
If you want to see if you have any directories with world write permission, use: