Posts tagged «script» Feed RSS

Here a small piece of code which will search for the duplicates in the path you supply. It will generate a new file which contains the commands for deleting those duplicates. Make sure you double check the resulting file! The script requires that you have fdupes installed. Install it in Ubuntu/Debian by running the following [...]

I just thought that you might be interested in a small script you can use in Hardy Heron. It uses the new UFW (Uncomplicated firewall) introduced in this new Ubuntu distro. The script is well commented, so everything is easy to understand. Here is the script: #!/bin/bash   ## set the default policy to drop [...]

If you are a MySQL user and you want to have a disaster recovery solution, or even as a simple backup, you can write small shell scripts based on mysqldump tool. For this, you need AutoMySQLBackup. It doesn’t have any real requirements (mysqldump of course is needed – in any mysql client package – and [...]

Unp is a small perl script which makes extraction of any archive files a bit easier. It support several compressors and archiver programs, chooses the right one(s) automatically and extracts one or more files in one go. Instalation: sudo apt-get install unp Usage: usage: unp file [file]… file: compressed file(s) to expand Use — to [...]

So you have a script of your own that you want to run at bootup, each time you boot up. This will tell you how to do that. Write a script. put it in the /etc/init.d/ directory. Lets say you called it FOO. You then run sudo update-rc.d FOO defaults You also have to make [...]