LINUX ALL ============ http://users.cis.fiu.edu/~tho01/psg/linux.html#kickstart http://cb.vu/unixtoolbox.

xhtml ========= LINUX BOOT ORDER ===================== http://unixbites.blogspot.com/2011/03/linux-boot-process.html

Tape drive installation ========================= http://www.linuxquestions.org/questions/linux-server-73/how-to-install-and-mount -dat-tape-drive-888071/ http://www.linuxquestions.org/questions/linux-hardware-18/help-w-scsi-tape-drive -258766/ =======> =======> cat /proc/scsi/scsi grep Ult* cat /proc/scsi/scsi grep Tape

SAN & WWN CONNECTIVITY ======================== [root@vfaul350 ~]# cat /proc/scsi/qla*/* grep adapter-port scsi-qla0-adapter-port=50060b0000881c92; scsi-qla1-adapter-port=50060b0000881c93; [root@vfaul350 ~]# cat /proc/scsi/qla*/* grep target scsi-qla0-target-0=50060e8004757902; scsi-qla0-target-1=50060e8004757922; scsi-qla0-target-2=50060e8004757923; scsi-qla0-target-3=50060e8004757942; scsi-qla0-target-4=50060e8004757962; scsi-qla0-target-5=50060e8004757963; scsi-qla0-target-6=100000e002433f02; scsi-qla1-target-5=100000e002233f02; ===================== QLOGIC DRIVER INSTALLATION IN LINUX ======================================== http://prefetch.net/blog/index.php/2009/05/02/installing-qlogic-drivers-on-cento s-linux-hosts/ http://www.cyberciti.biz/faq/how-to-scan-new-luns-on-linux-with-qlogic-driver/

com/support/viewContent. Additionally.html http://www.fc2.html Time Zone Setting ======================== zdump -v /etc/localtime grep 2011 rpm -qi to check the status of package installed hostname.com.rpm -qa grep tzdata vfaul057.1 http://www.do?externalId=3655154&sliceId=1 =========================== The passwd command and passwd aging. The passwd command has the obvious use of changing passwords.au tzdata-2006a-2.com/advice/tips/timezone.http://pbraun.redhat.info/linux-server/how-to-change-timezone-of-linux-servers .yusufozturk.html http://www.com/doc/sysutils_linux/hba-multipath.vodafone. it i s used by the root user to: * * * * * ocked * Lock and unlock accounts (-l and -u) Set the maximum number of days that a password remains valid (-x) Set the minimum days between password changes (-n) Sets the number of days of warning that a password is about to expire (-w) Sets the number of days after the password expires before the account is l (-i) Allow viewing of account information in a clearer format (-S) Login attempt from ip address and users ======================================= lastb less lastb -R less .novell.nethence.

enter: # faillog -l 180 -u vivek # faillog -l 180 Password chage after login .au Sep 28 23:22:26 vfaul057 sshd[2333 ========================================================== How Do I Display All Failed Login Attempts For a User Called vivek? Type the command as follows: # faillog -u vivek To display all failed login attempt try: ========================================== faillog -a To display failed login attempt for user root with following command: ================================================================ $ faillog -u root PAM Configuration To Recored Failed Login Attempts ======================================================= http://www.com.html Task: Lock Account To lock user account to 180 seconds after failed login.cyberciti.vodafone.biz/tips/rhel-centos-fedora-linux-log-failed-login.Password Never expire command ================================= Login attempt failed and ssh Login status in Linux ================================================== hostname.tail -f /var/log/secure vfaul057.

ssh/id_rsa Step 3 add id_rsa key in server which we want to access at .) PasswordLess Account in Linux ================================== passwd -d test How to lock and unlock an user account in Linux ======================================== To lock a user account (liz) from logging in: [root@techpulp ~]# passwd -l liz To unlock a user account (liz): [root@techpulp ~]# passwd -u liz SSHD password less authentication ===================================== Step 1 ssh-keygen -t rsa Step 2 Then copy file id_rsa file located .ssh/authorized_keys2 Done ssh key password less ==================================== .============================= chage -d 0 {user-name} # chage -d 0 tom Password Aging Never expiry ======================== chage -I -1 -m 0 -M 99999 -E -1 rt083742 Password Lock and unlock status ================================== [root@techpulp ~]# passwd -S mark mark PS 2009-01-21 0 99999 7 -1 (Password set.ssh/authorized_keys2 /home/user/. unknown crypt variant.

htm l http://publib.htm DISK SPACE ============== How to find large files and directories in Unix/Linux http://vasfeeds. Suppose we want to find top 10 disk utilizing files with sizes in the range of 400MB ~ 600 MB.html a) Allow jadmin to run various commands: jadmin ALL=/sbin/halt.com/infocenter/lnxinfo/v3r0m0/index.biz/tips/allow-a-normal-user-to-run-commands-as-root.org/docs/5/html/5. /etc/init.centos. as root without authenticating himself: jadmin ALL= NOPASSWD: /sbin/halt c) Allow user charvi to run any command from /usr/bin directory on the system de v02: charvi dev02 = /usr/bin/* =========== ====== LVM In Multipathing ====================== http://www.1/DM_Multipath/multipath_logical_volumes.e.ibm.com/operating-systems/how-to-find-large-files-and-directories-in -unixlinux/ 1 find /export/home/mml/ -size +400000 sort 2 To find the files in a specific range. /bin/kill.boulder.Sudo privileges all and limited ================================= http://www.cyberciti. you can use the following command: r head 3 .jsp?topic=%2Fliaai %2FmultiBcs%2Fliaaimpbsclvm. we can mention the size twice.d/httpd b) Allow user jadmin to run /sbin/halt without any password i.

Entries in the crontab are separated by newline characters.sh ============================ Hard Disk health ======================= http://blog.com/monitoring-hard-drive-health-on-linux-with-smartmonto ols/ check the overall health: #smartctl -H /dev/sda #hdparm -tT /dev/hda dmidecode output ================ http://www.shadypixel. Each crontab contains six fields separated by spaces as s hown below: Minute Hour Day Month Weekday Command Each field is explained below: Minute: 0 ~ 59 Hour: 0 ~ 23 Day: 1 ~ 31 Month: 1 ~ 12 Weekday: 0 ~ 6 (Sunday to Saturday) Command: A shell file which you want to execute routinely or at a particular tim e.com/2008/11/how-to-get-hardware-information-on-linux-usi ng-dmidecode-command/ WWN .thegeekstuff. An example of a crontab job is shown below: 0 1 15 * * /backup.<36 SMSC :/export/home/mml/tmp> find /export/home/mml/ -size +400000 -size -600000 sort -r head -10 ========== CRON job A crontab contains entries for a cron job.

4. and icmp. Note that you don't have to type proto # tcpdump icmp port // see only traffic to or from a certain port # tcpdump port 3389 Monitor all packets on eth1 interface #tcpdump -i eth1 #tcpdump -ni eth0 Monitor all traffic on port 80 ( HTTP ) #tcpdump -i eth1 'port 80' .2. udp.com/2010/08/hba-wwn-address/ $ cat /etc/redhat-release Red Hat Enterprise Linux Server release 5. dst // find traffic from only a source or destination (eliminates one sid e of a host conversation) # tcpdump src 2.3.3 (Tikanga) $ cat /sys/class/scsi_host/host1/device/fc_host:host1/port_name 0x2100001c111111c1 $cat /proc/scsi/qla2300/1 tcpdump =============== http://www.biz/faq/tcpdump-capture-record-protocols-port/ http://danielmiessler.6 # tcpdump net 1.========== http://www.thegeekstuff.5 # tcpdump dst 3.5.3.4 # src.3.cyberciti.com/study/tcpdump/ # host // look for traffic based on IP address (also works with hostname if you' re not using -n) # tcpdump host 1.4.2.0/24 # proto // works for tcp.

3.Monitor all traffic on port 25 ( SMTP ) #tcpdump -vv -x -X -s 1500 -i eth1 'port 25' tcpdump: Monitor ALL eth1 Traffic Except My Own SSH Session #tcpdump -i eth1 -s 1500 port not 22 You can skip additional ports too: #tcpdump -i eth1 -s 1500 port not 22 and port not 53 You can also use ip or hostname: #tcpdump -i eth1 port not 22 and host 1.4 DNS traffic via dnstop ============================= http://www. type the following command at a shell prompt to monitor traffic for eth0 interface: # dnstop {interface-name} # dnstop eth0 # dnstop em0 # dnstop -l 3 eth0 # dnstop -t -s eth0 * -s Track second level domains * -t Track third level domains How to diffierenate from Local disks vs SAN ==================================== [root@saturn block]# ls -l /sys/block/*/device How to rescan Fiber Channel and SCSI storage Posted by linux on July 21. 2011 You can force a rescan for SCSI drives like this: echo .>/sys/class/scsi_host/host Same for FiberChannel: echo 1? >/sys/class/fc_host/host Also. . you can reboot the system to Rescan.2.biz/faq/dnstop-monitor-bind-dns-server-dns-network-trafficfrom-a-shell-prompt/ How do I view dns traffic with dnstop? Simply.cyberciti.

Sign up to vote on this title
UsefulNot useful