Monday, January 26, 2009

Bash Shell Tutorial

Linux uses the Bourne-again(Bash) shell. A few of the must know commands for working your way through the shell
pwd : show path of present working dir
ls : list contents of pwd
cd : change dir
rm : to delete files, to delete dir use the -r flag with rm
emacs : text editor to open file
su : switch user
sudo : execute a command with temporary root privileges
chmod : change privileges for a file, value 777 specifies r,w,x for root,group and others
ps : list current processes
kill : stop processes that are not responding
poweroff : shutdown system
reboot : reboot system
init : switch between run levels, 5 is the default run level for multi-user, networking and gui
/etc/init.d/gdm stop : to stop the gnome desktop manager and enter shell mode
/etc/init.d/kdm stop : to stop kde desktop manager
startx : start the xserver
ifconfig : configure network adapter
All services are in the /etc/init.d directory

mount : to mount hard drives, cds
mount -t iso9660 /dev/cdrom /media/new : will mount a cd in the new folder in media dir
mount -t ntfs /dev/sda1 /mnt/c : will mount ntfs partition 1(scuzzy device)in c folder in mnt dir
umount : to unmount a mounted drive, if device busy error comes use -l option for lazy unmount
To automount a partition on boot add the mount entry to fstab file in /etc directory

cp : copy
mv : move
man : this is the most useful command, typing man command will give you the manual pages for that command which describe the command in detail and how to use it

ctrl+alt+(F1-F6) : enters any of the six available terminals
ctrl+alt+F7 : switch back to gui mode from the terminal


rpm -i : to install an red package manager package
rpm -e : to remove an installed rpm package

To manually compile a binary executable with a make file, execute the following sequentially
./configure
make
make install

For a complete guide to master the shell commands, refer linux guides like the Red Hat guide. A good video for learning linux is given by CBT nuggets.
The best way to learn linux is through experimentation, use a virtual software if ur reluctant to install linux. Qemu with pendrive linux is what i used to learn and experiment with linux. It is available for download at the following link :
http://www.pendrivelinux.com/portable-qemu-persistent-pendrivelinux/
Using this u can run linux within windows, just like any normal windows app without rebooting or installing anything.

Sunday, January 25, 2009

Lightweight Virtualization

It is the latest trend in virtualization. There are 2 techniques, containers and paravirtualization.
Containers virtualize an OS's operating environment, not the hardware.
Paravirtualization virtualizes part of the operating environment and selectively emulates necessary hardware.
Both these are faster and much more efficient than traditional virtualization.
So, those of you working on VMWare and other traditional virtualization platforms, try out the new products like XenSource's Xen and Linux -VServer. Other free packages include Qemu and Boch's.
As for why go for virtualization, the benefits are limitless. Try out all unstable software and do all your experimentation in virtual environments without affecting your host OS or valuable data. Run multiple servers on a single server hardware.

Thursday, January 22, 2009

A few computer tips

Speed up the boot process
Run msconfig utility from start->run. In the startup tab uncheck non critical items.Be careful not to remove items in the system 32 dir.

Set the page file as static
Go to start->control panel->system->advanced.
Click on virtual memory settings.Go to advanced tab and click change.Set initial size and maximum size as the same, optimally 1.5 times the system RAM.

Leave a few Gb of free space in C: drive and defrag regularly


Few Amazing Videos!!!

Loading...