I have downloaded asterisk (trixbox) CD and have tried installing it via VMware on my Windows XP but asterisk is failing to detect the virtual drive of Vmware and installation is not successful , I wonder if someone has successfully installed asterisk on vmware in Windows?
EDIT: It is working now, you just need to select IDE drive instead of SCSI in the virtual machine, this parameter is not modifiable so you will need to create a new virtual machine having IDE option for disk drive.
Yes you can unpack a tar archive which has gz / bz or any other UNIX native form of compression from SSH or telnet but if you upload a zipped archive to your server than uncompressing/extracting it is not always simple and sometimes not even possible.
The only way that I have found is via PHP, but for that the server must support PHP unzip function, you make a simple php script that tells the sever to unzip the archive.
You cannot unzip directly from SSH unless you have the unzip package installed, which most of the server don’t have.
Unzip or extracting from FTP is not possible as FTP is only a file transfer protocol and is very restricted in what it can do.
Now that is a very basic thing! But it is not that simple when you are doing it for the 1st time and you don’t have much knowledge of scripting.
Suppose you want to write a script that counts that in how many lines the name of certain fruit came in a file
From command line you can do this by
grep –c apples datafile.txt
Now if you many things that you need to count then you will have to type the above commands for each of them but this can be also done through a small script but the question is that if I have many different data files than how I run the same script on all of them? The answer is in $1, $1 is the 1st parameter given from the command line to the script (which would be the name of data file in our case
#!/bin/bash
grep -c apples $1
grep -c mango $1
grep -c orange $1
save the above script in a file ‘myscript’ set execute permissions and than for any datafile you can all the script by
./myscript datafile
Just to let everyone know, I passed the LPI 101 exam, that was a few months ago in February. Now I just need to go through the LPI 102 exam to complete the Level 1 certification and till now due to my busy schedule I have not even started the preparation for the 102 exam but I hope to take the exam by the end of this year.
The LPI 101 was up to the expectations, neither too easy nor too hard and had a good learning curve; I advise LPI for everyone who wants to get started in the UNIX world.
I will recommend Roderick W. Smith LPI Study guide which has been published by Sybex, don’t go for the IBM developer works tutorials, they are good but only if you have too much time at hand as they contain much extra information which is not needed.
You can enable or disable the mail notification in a terminal window by the command biff
biff -y enable the mail notifications
biff -n disables the mail notifications
History file in Linux is the file in which the command history is stored, it is created in the home directory of every user, e.g. in case the user is Joe and his home directory is /home/Joe than the file will be /home/Joe/.bash_history
You can also find the path to your history file using the command $HISTFILE , if it is not set than the command history is not saved when an interactive shell exits
You can open and extract the content from gzipped in Windows easily using WinRAR however you cannot create a gzip archive in Winodws using WinRAR, a good tool which can be used to both create and open gzip files in windows is Powerzip, you can get its trial version from powerzip.biz
Powerzip can also be used to work with bz2 archives in windows
dmesg command
The messages that appear on the screen while Linux in booting are saved in a file named /var/log/dmesg these messages can again be view for troubleshooting and diagnostic purposes etc either by displaying the file /var/log/dmesg or by simply giving the command dmesg at the prompt
du command in Linux is used too check the amount of disk space being used by a directory and its sub directories , if we give the du command without specifying a directory than the commands work for r the pwd or the directory in which we are working currently
Here are some of the switches than can be used with the du command
du -a Shows counts for all files and directories.
du -b Displays size in bytes.
du -c Prints a total for all arguments after they are processed.
du -h Creates human readable output, appending letters such as M for megabytes.
du -k Displays size in kilobytes.
du -m Displays size in megabytes.
du -s Displays a summary total for each argument.
du -x Skips directories containing file systems other than the one contained in the argument
The other day I was trying to connect to my Suse Linux box from Windows via SSH and had already connect the two by Ethernet cable , I was able to ping both machines from each other but SSH (I was using Putty in Windows) was not working from Windows and I was getting the error that “Network error: connection timed out”
On investigation I found that it was the Suse’s firewall which was causing all trouble, I disabled it and SSH started working perfectly
So If you are having the same problem than please do check for the firewall in Suse as it is enabled by default