sudo

Automatic Actions – Run or Walk Those Cron Jobs

You’d be surprised what you can accomplish when you aren’t even close to your computer. Using Rsync you can completely backup your /home directory. I back it all up, except one directory, which I handle differently.

rsync --exclude="~/.VirtualBox" /home /media/backup

I mount a usb hard drive to /media/backup. Make sure you set proper permissions:

sudo chown user:user /media/backup

Now you can rsync your home directory without the need for a sudo.

Rsync only updates files that have timestamps that are newer than the previously transferred. This makes it fast; real fast!. I backup my machine using an rsync command once a day. Open crontab:

sudo crontab -e

Add a line:

0 0 * * * rsync --exclude="~/.VirtualBox" /home /media/backup

The above will run the command every day at 12 AM. Your /home directory with be synchronized with /media/backup/home.

Then comes your virtual machines. Use Vboxtool!!!! Check out this post for more info about the tool.

Set /media/backup as the backup directory in /etc/vboxtool/vboxtool.conf. Then add the following line as a cron job.

0 1 * * * vboxtool backup WebServer

Replace WebServer with the name of your virtual machine. This cron job will run every day at 1 am.

Ubuntu Karmic – Mac Mini – MythTV

I gave up on OSX. I could not get the media center working the way I wanted. Plex and XBMC have their bugs, as previously posted, twice, preventing predictable functionality. MythTV for OSX simply is not as refined as its native Linux counterpart. It feels like running Windows applications via wine. I just scrapped OSX for Ubuntu Karmic. Out of the box, off of the cd, things work great. Audio works perfect. What didn’t work? The Mac Mini remote control. I tried for a day to get it to work the hard way. I saw that /dev/usb/hiddev1 was working and displaying data; shown with cat. But lirc would not bind to the device. Ultimately I removed the program, and ran a system update. Problem resolved; clearly a bug report was filed and a resolution provided.

Fanart and coverart work fine. The Linux based fronted is seamless compatible with the Linux based MythTV server. I didn’t even need to input the servers ip information manually. I did have to set the repeat feature, for each key in ~/.lirc/mythtv.

Now all I want is to have MythTV sleep the system and wake the system. I get it to sleep the system by making the halt script sudo pm-suspend. Adjust your /etc/sudoers files to allow passwordless sudo for /usr/sbin/pm-suspend. The halt script is configured in setup-general settings. Waking the computer is another thing that I have yet to get working.

Gnome Panel frequency Scaling Applet

By default the Gnome frequency scaling applet does not vary the frequency of the CPU. If your computer supports frequency scaling then the gnome panel applet can server quite useful. The only requirement is to reconfigure the applet to operate with root permissions: sudo dpkg-reconfigure gnome-applets

Avant Window Navigator Development Version 0.3.1 Plus

To install the development version, which has the benefit of up to date applets and code, install the appropriate apt source, sudo apt-get update, and sudo apt-get install avant-window-navigator-trunk awn-manager-trunk awn-extras-applets-trunk:

deb http://ppa.launchpad.net/awn-testing/ubuntu hardy main
deb-src http://ppa.launchpad.net/awn-testing/ubuntu hardy main

Sudo Apt-Get Update

The sudo command is a program that is not included in the Debian project, although it is a standard, and well integrated component of upstream distributions such as Ubuntu. The sudo command allows a user to access root functionality, without having to “su” or login to the root account directly. On Debian systems the /etc/sudoers file must be configured in order to authorized sudo functionality, whereas on Ubuntu distributions the sudoers file automatically accommodates system users.

The Apt-Get command is part of the aptitude application, and is designed for package management, and software updating. The application supports dependency resolution, and is analogous in functionality to the yum package management system.

Passing the update argument to the Apt-Get command results in a system update process. This process will contact the configured repositories and compare them to existing files on the local system. If an update is possible, the “sudo apt-get upgrade” command will process the respective program upgrade.

You can enter these commands directly into a terminal. For more information about the terminal, its location, and some examples visit:

http://www.bgevolution.com/blog/index.php/terminal-location-debianubuntu-a-beginners-tutorial/

All that the previous link will show is the terminal location. Click the applications menu, and in the accessories tab is the terminal. You can also hit alt-f2 to get a applications windows; enter “gnome-terminal” to open a terminal. If you want to change the entire terminal, and not open a terminal emulator press cntrl-alt f1. This will change your entire desktop terminal to a command prompt. Press cntrl-alt f7 to get back to your default shell and desktop.