Category Archives: Linux

Uncompress on the fly when copying a file from a remove location with scp

Don’t use scp, do it with ssh: ssh backups@server “cat /home/backups/backup_2010-09-27.tar.gz”| tar zxvf – You can probably use something similar also for: Compress on the fly when copying a file from a remove location with scp

Posted in Linux Command Line | Tagged , | Leave a comment

Setting up an encrypted volume on an external hard drive on CentOS

Make sure the version of your kernel is 2.6.16 or later with support for device mappers. Please replace XXXXX with the device Linux allocates the driver to (i.e.: /dev/sdc1). Use the dmesg command to find that out. Preparing the volume … Continue reading

Posted in Redhat / CentOS, System Administration | Leave a comment

Linux bash – tar tricks

Change directory: tar xzvf /var/backups/dbserver/dbserver-backup*.tar.gz -C /var/backups/dbserver Specifing the destination file: tar –create -zvPh -f /tmp/backup.tar.gz /usr/local/bin /usr/local /etc/var/spool/cron /var/svn /home/*/.ssh /home/*/.bash*

Posted in Linux Command Line | Tagged | Leave a comment

Ubuntu Linux on Acer Aspire AO751h

Don’t use the Ubuntu Netbook Remix but the Desktop version. To fix the monitor resolution: https://wiki.ubuntu.com/HardwareSupportComponentsVideoCardsPoulsbo/ Wi-fi should work out of the box

Posted in Debian / Ubuntu / Kubuntu | Leave a comment

Linux command Line – copy a file from remote to local

Copy a file from a remote location to a local directory (for example to burn a backup on DVD): scp backups@server1:backup20100105 local/path

Posted in Linux Command Line | Leave a comment

PHP function to get the most recurrent words in a file – it uses Linux command line

/** * Extracts the most recurrent one-word and two-word terms in a file * Filters out some common stop words and you can also pass extra ones * * @param string $filepath * @param int $minWordLength – the minimal word … Continue reading

Posted in Linux Command Line, PHP | Leave a comment

Install KAlarm on Gnome

You have to install kdepim: _ yum install kdepim (on RedHat and CentOS) _ apt-get install kdepim (on Debiam/Ubuntu) By doing that you can use KAlarm (that actually is a KDE program)

Posted in Linux | Tagged , | Leave a comment

How to Download Movies & Files on Linux

_ Find the torrent with http://www.mininova.org/ or search on Google “Gladiator download torrent” _ Use Transmission to download the torrent _ opersubtitles.org

Posted in Linux | Leave a comment

how to install flash in Firefox for CentOS

* Go to youtube.com and try to play a video. You should not be able to play it * Instead of the video, there should be a link like ‘Install Flash’ * You should be redirected to the Adobe website … Continue reading

Posted in Redhat / CentOS | Leave a comment

Linux Bash: Append and Prepend Strings to Files

I want to append the string “BYE” to the file test.txt echo “BYE” >> test.txt Now, I want to prepend the string “HI” to the file test.txt echo “HI”|cat – test.txt > /tmp/out && mv /tmp/out test.txt

Posted in Linux Command Line | Leave a comment