Debian/Ubuntu Tips and Tricks

Debuntu

Debian/Ubuntu Tips and Tricks

How-To: Set up a L2TP over IPSec VPN using a Radius backend

Posted by chantra on 18th June 2010

This entry is part 1 of 3 in the series How-To: Set up a L2TP over IPSec VPN using a Radius backend

Even though I pretty like OpenVPN, there is still some devices that might not support the TUN/TAP driver needed by OpenVPN.

Take IPhones, Android phones for instance, you need to root them in order to get that feature, assuming somebody has already cooked a ROM for your device.

L2TP is quite and old standard that allow setting up VPNs.

On the other end, it does not provide any kind of encryption mechanism, and as such, it is pretty common to get L2TP running over an IPSec link.

Read the rest of this entry »

Tags: , , , ,
Posted in Administration, HowTo, Networking, System | 1 Comment »

How-To: Disable pulseaudio and sound in GDM

Posted by chantra on 14th June 2010

If like me you use MPD as a service daemon to listen to music, you might be annoyed anytime GDM start a pulseaudio process which prevents MPD from accessing the sound device.

Typically, the output of ps will produce the following output:

$ ps aux | grep pulse
gdm 1371 0.0 0.4 98180 4776 ? S<sl Jun13 0:00 /usr/bin/pulseaudio --start --log-target=syslog
gdm 1411 0.0 0.2 10748 2968 ? S Jun13 0:00 /usr/lib/pulseaudio/pulse/gconf-helper

Read the rest of this entry »

Tags:
Posted in HowTo, System | No Comments »

How-To: Mounting /dev in a chroot environment

Posted by chantra on 8th May 2010

When working in a chrooted environment, there is a few special file systems that needs to be mounted so all programs behave properly.

For instance, grub will need to access your disk devices....

While most special file systems might be mounted with:

# mount fstype -t fstype /tmp/chroot/mountpoint

Where fstype will be sysfs, proc, /dev is not following this rule.

Read the rest of this entry »

Tags:
Posted in Administration, HowTo, System | No Comments »

How-To: Network-Manager-OpenVPN overwrites default route

Posted by chantra on 2nd March 2010

I was trying network-manager-openvpn plugin today on Lucid, I could import my configuration, DNS was set up correctly upon connection/disconnection, route imported correctly (almost :)).

One issue though is that it was also changing the default route to the VPN tunnel while this should not happen.

Read the rest of this entry »

Tags: ,
Posted in HowTo, Networking | No Comments »

How-To: Rescan a SCSI bus without Rebooting

Posted by chantra on 12th December 2009

When you hotplug a hard drive in a virtual machine, the drive do not show in fdisk -l output until you reboot your VM.
In order to get the drive to appear, the SCSI bus need to be rescanned.

Read the rest of this entry »

Tags: , ,
Posted in HowTo, System | 4 Comments »

How-To: Changing the default text editor

Posted by chantra on 16th September 2009

There is a few software that will use the editor command to find out what text editor to use. Example commands will be dch to add a new .deb changelog entry, revision control softwares when prompting for a commit message ...

Read the rest of this entry »

Tags:
Posted in Administration, HowTo, Softwares | No Comments »

Vmware Workstation: DNS not working with NAT

Posted by chantra on 8th April 2009

Lately, I have been experiencing a funny network issue when using VMware Workstation VMs with NAT interface. Roughly, the IP network was working fine, but DNS resolution was not anymore. It happened intermittently, but I could see that this mainly happened when I was suspending my laptop, going to another location and resuming.

Forcing the VM to use a public DNS would solve the issue.

Read the rest of this entry »

Tags: , ,
Posted in HowTo, Softwares, Virtualization | No Comments »

How-To: Redirecting network traffic to a new IP using IPtables

Posted by chantra on 6th December 2008

While doing a server migration, it happens that some traffic still go to the old machine because the DNS servers are not yet synced or simply because some people are using the IP address instead of the domain name....

By using iptables and its masquerade feature, it is possible to forward all traffic to the old server to the new IP.

This tutorial will show which command lines are required to make this possible.

Read the rest of this entry »

Tags: , ,
Posted in Administration, HowTo, Networking | 14 Comments »

How-To: Bzr over ssh with no bzr server

Posted by chantra on 21st August 2008

Bazaar (bzr) is a distributed version control system (VCS) sponsored by Canonical and thus bzr is widely used by the Ubuntu community.

Like any vcs, bzr will let you track the different version of your code locally and let you push the changes to a remote server.

One cool feature of bzr is that you can maintain a remote copy of your code history without having a bzr server running, nor having a copy of bzr on the remote server running and simply by using ssh to transport the data.

This tutorial will not explain how bzr works, but will show the couple few step to create your local repository, add a few files, commit the changes, push them to a remote server and copy the branch newly created to another machine.

Read the rest of this entry »

Tags: , ,
Posted in Administration, HowTo, Softwares, System | No Comments »

How-To: encrypted partitions over LVM with LUKS — page 3 — install and config

Posted by chantra on 12th July 2008

This entry is part 3 of 3 in the series How-To: encrypted partitions over LVM with LUKS

4. Installing the system

we are now going to install the distro over our layout. Start the installer and make sure you choose manual partitioning. Then set up your filesystem like the one on the screenshot.

luks encryption over-lvm ubuntu installer

luks encryption over-lvm ubuntu installer

Read the rest of this entry »

Tags: ,
Posted in Administration, HowTo, System | 3 Comments »