HowTo Archives

Jacob from FOSSwire has a nice tip that will allow you to quickly open any folder from your GNOME Desktop.

While on your desktop (either with no windows open or with the desktop focused) type / (forward slash). Now type in a folder path and hit Enter. The directory will be opened in a new Nautilus window. On top of that, it will also autocomplete most paths.

Read the rest of the article..

Compile an Ubuntu Kernel from scratch

This complete guide to compiling an Ubuntu kernel is very well detailed. The purpose of compiling your own kernel is to tune it specifically to your hardware specifications, as sometimes the install CD provides you with a generic kernel set up.

How to install Fedora 8 Desktop

This document describes how to set up a Fedora desktop – including how to enable special mouse buttons, improve laptop support (depending on your model), set up printers (especially HP) and the usage of Compiz Fusion. The result is a fast, secure and extendable system that provides all you need for daily work and entertainment.

This howto is a practical guide without any warranty – it doesn’t cover the theoretical backgrounds. There are many ways to set up such a system – this is the way I chose.

Read more..

Quickzi: Delete files that are a year old

Here’s a quick tip on how to delete files that are a certain amount of days old. In my example, I use 365 days.

find / -type f -mtime +365|xargs rm -f

You could easily replace 365 with any amount of days to achieve a different goal.

If you’re like me, you like the option of being able to open certain applications on the fly, simply by selecting them from your right click menu. It is possible to add your most used, or any applications to the Ubuntu right click menu with a tool called Nautilus Actions.

1. The first thing you need to do is install the Nautilus Actions application:

sudo apt-get install nautilus-actions

2. After it is installed, navigate to your System > Preferences menu and select Nautilus Actions Configuration

Adding Shortcuts to the right click menu in Ubuntu

You should now see the Nautilus Actions main screen

Adding Shortcuts to the right click menu in Ubuntu

3. Click the Add button and you should see the Add a New Action screen

Adding Shortcuts to the right click menu in Ubuntu

4. Fill out the Menu Item & Action properties with whatever you would like in your right click menu. Above, you can see I am using VLC as an example.

Next, click on the Conditions tab.

Adding Shortcuts to the right click menu in Ubuntu

5. Under the Conditions tab you need to make sure that Both is selected under “Appears if selections contains”.

Next, click on Advanced Conditions

Adding Shortcuts to the right click menu in Ubuntu

6. First, uncheck the “File / Local Files” box. Second, in order for the menu items you add to appear every time you right click, you will need to add a blank entry under the Advanced Conditions. To do this, click on the + and erase “new-scheme” and “new-scheme description” so that both entries are blank.

7. Click OK.

8. You now have added your first right click menu item. In order for the item to appear on your right click menu, you need to restart the nautilus daemon.

killall -HUP nautilus

Now you should be able to see the VLC media player on the right click menu.

Adding Shortcuts to the right click menu in Ubuntu

To continue adding more items to the menu, repeat steps 3 through 8 until you are satisfied.

Heres a quick tip on removing blank lines and comments from a file using sed.

sed ‘/ *#/d; /^ *$/d’ file_with_blank_lines_and_comments.txt > new_file_without_blank_lines_and_comments.txt

Cheers!

Need to find out what all the file types in a certain directory are? Simple!

Execute the following on the command line:

find /path/here/ -type f -print | xargs file

I typed: find /home/adam/test/ -type f -print | xargs file

The output will look something like this:

/home/adam/test/music.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, mono 44100 Hz
/home/adam/test/package.deb: Debian binary package (format 2.0)
/home/adam/test/file.tar.gz: gzip compressed data, from Unix, last modified: Tue Jun 20 12:51:11 2006
/home/adam/test/widget.xml: ASCII text, with CRLF line terminators
/home/adam/test/logfile.txt: empty

Cheers!

Quickzi: How to Jail VSFTPD Users

If you’re worried about FTP users exploring outside of their home directory, you want to set up what is called a chroot jail.

To do this, open the /etc/vsftpd.conf file:

vim /etc/vsftpd.conf

and make the following modifications (line should be uncommented):

chroot_local_user=YES

After you save the file, restart vsftpd:

/etc/init.d/vsftpd restart

Now all users will be jailed to their own home directory when using FTP.
Now, lets say you only want to jail certain users, and allow other users to browse other directories. To do this, you’ll want to again edit the configuration file.

vim /etc/vsftpd.conf

uncomment the following lines:

chroot_list_enable=YES
chroot_list_file=/etc/vsftpd.chroot_list

After you save the file, restart vsftpd:

/etc/init.d/vsftpd restart

Now you will need to create the /etc/vsftpd.chroot_list file and add in users you do NOT want to jail. By default, all users will be jailed. In the /etc/vsftpd.chroot_list file you can specify what users to allow to browse all directories.

HOWTO: Setup a Debian/Ubuntu LAMP Server

Build Your Own Debian/Ubuntu LAMP Server – Quick & Easy Do it Yourself Installation

This howto tutorial was written by Scott from MySQL-Apache-PHP.com.

  • Apache 2 – Linux Web server
  • MySQL 5 – MySQL Database Server
  • PHP4/5 – PHP Scripting Language
  • phpMyAdmin – Web-based database admin software.

Note: Linux + Apache + MySQL + PHP/Perl together commonly known as LAMP Server.

Read the rest of this entry

Initial Slackware Configurations

There are many settings I find myself adjusting after every Slackware installation I complete. This article takes place immediately after an installation of Slackware 11, logged in as root for the first time. Here are some of the settings I adjust: Read the rest of this entry