jump to navigation

UBZ News October 31, 2005

Posted by Carthik in ubuntu.
10 comments

Sadly, there is very little news from the Ubuntu Below Zero (henceforth UBZ) conference that is currently underway in Montreal, Canada. I scoured Technorati and Feedster and came up with two small fish, which is all!!!

For Dapper+1, I promise I will blog every minute of the conference, provided I can find a way to bankroll the ticket to the conference. Some one should seriously report on stuff as it happens – it could be such a great PR exercise. Maybe I will add a paypal jar to this blog, and see if I can collect at least 50% of the money for the plane ticket. The rest I should be able to muster. I’ll be the unofficial reporter/scribe :)

A few UBZ photos are up on Flickr. Those laptop Ubuntu stickers – well, I need one!!!. So if someone can grab one for me, I will be eternally indebted!

How to mount a remote ssh filesystem using sshfs October 28, 2005

Posted by Carthik in ubuntu.
204 comments

SSH is protocol to transfer files securely. Like FTP, but more secure. Many hosting services offer their client the ability to remotely login to their hosting account using ssh. Transferring files to an from an ssh account can be done using the scp command. However, it would be neat if you could mount a remote folder that you can access using ssh on your local computer, so that you can access files on an ssh account just like they were local files on your pc, right? Well now you can! Mount a folder in an ssh account, edit the files locally and save the files, and the file on the ssh server changes too! Isn’t it awesome!!!

We will use sshfs to acheive our goal. The following guide will step you through the process of mouting file systems over ssh on Ubuntu 5.10 Breezy systems.

sshfs:
       sshfs  is  a filesystem client based on the SSH File Transfer Protocol.
       Since most SSH servers already support this protocol it is very easy to
       set  up:  i.e. on the server side there’s nothing to do.  On the client
       side mounting the filesystem is as easy as logging into the server with
       ssh.

Install sshfs by doing a:
$sudo apt-get install sshfs

This will also install fuse-utils and libfuse2, which are required.

Now, let us create a local directory where you want the files mounted. You should create the directory and make yourseld the owner of the directory:

$sudo mkdir /media/dir-name
$sudo chown your-username /media/dir-name

Where “dir-name” is the name of the directory on your local computer where you want to access the files from the remote computer. Say I want the files on the server to be available at /media/home-pc. I want this because the “server” in this case is the desktop I have at home, which allows me to access it through ssh. Let us use “home-pc” as an example for this guide. “your-username” is your username on the local computer.

Go to System->Administration->Users and Groups, select the group “fuse” and then add yourself to this group.

If you prefer to do it the easy way, on the commandline, then use
$sudo adduser your-username fuse

I don’t want to provide a terminal command for adding yourself to a group since there doesn’t seem to be an easy way to add yourself or any user to a group. The only command I know of is the usermod -G command and for this command, you need to list all the groups the user should belong too, even the ones that he/she is already a member of! Anyone know any better on how to add a user to a new group, without having to know what groups he/she is already a member of?
Thanks Shot.

For security reasons, the /usr/bin/fusermount binary is installed in such a way that users cannot execute it. You will have to log out and log in again, to add yourself to the group “fuse”.

Once you have done the above, you can use sshfs to mount the directory you need on the remote host to your local system!

For example, say I want to mount the “/stuff” directory on my home-run server, which has the domain name “example.com”. I would do it by executing the following command:
$sshfs example.com:/stuff /media/home-pc

Where “/stuff” is the folder on the computer with the domain name “example.com”, which I want to mount and access on my local computer at the location /media/home-pc. Remember that the /media/home-pc directory must exist and be owned by you, the user. I already mentioned how to do this in the initial part of this guide.

If you get the following error:

fusermount: fuse device not found, try ‘modprobe fuse’ first

You will have to load the fuse module by doing:
$sudo modprobe fuse

You can add fuse to the modules that are loaded on startup by editing the file /etc/modules and adding a line with only the word “fuse” in it, at the end.

and then issue the sshfs command above again.

To unmount the directory once your work is done, use the command:
$fusermount -u

for example, in my case, I would use
$fusermount -u /media/home-pc

Hat tip: Jorge
More Info: SSH filesystem

Official Promo Stuff, CD Covers – DIY Marketing October 27, 2005

Posted by Carthik in ubuntu.
5 comments

If you cannot wait to get the latest Breezy CDs, and want to make your own Ubuntu CDs, or if you want to display your love for Ubuntu in a public manner using posters, look no further than the Do-it-yourself Marketing page on the wiki. That is the one place to get Ubuntu CD cover sources, CD labels and posters. All official, all the time.

System Sounds and Application Sounds October 26, 2005

Posted by Carthik in snippets, ubuntu.
5 comments

Some of the applications that are installed on your system do not use the esd (e-sound daemon, where e = enlightened) driver for outputting audio. The result — while you can hear the system beeps, hoots and whistles, you can’t hear the sound from the application you are running. If this is the case, then fear not, esddsp will rescue you!

Install esound-clients the usual way:
$sudo apt-get install esound-clients

and then add a “esddsp” to the command you use to start your application for which you cannot hear sounds yet:
$esddsp tuxracer

The above will re-route the sounds emanating from tuxracer, which is a neat little game, through esd, so you can hear the game sounds and the system sounds.

Thanks for Charles Mauch on the ubuntu-users mailing list for the tip.

Baobab – Graphically Analyze File Trees October 25, 2005

Posted by Carthik in applications, ubuntu.
6 comments

Baobab is cool little tool to analyze disk space usage graphically. It displays the space used by directories on your hard drive, so you know what’s eating up all your space. It is sort of the like the application called “tree” that’s available for windows. Baobabs are large trees, usually found in Africa – so that’s a real nice name for the tool.

You can, of course install it in Breezy by doing a
$sudo apt-get install baobab

Nautilus Script to Mount ISO files October 24, 2005

Posted by Carthik in ubuntu.
31 comments

David Carney, subscriber to the ubuntu-users mailing list had shared the following script to enable mounting ISO cd images from within the Nautilus File Manager, by right-clicking on the iso file to be mounted. You have to create a /media/ISO directory before you can use the script. For more details on how to install scripts for Nautilus, read the How to Install a Script part of the g-scripts faq.

I quote the entire mounting and unmounting script below:


MOUNT ISO FILES:


#!/bin/bash
#
for I in `echo $*`
do
  foo=`gksudo -u root -k -m "enter your password for root terminal
access" /bin/echo "got r00t?"`
sudo mount -o loop -t iso9660 $I /media/ISO
  done
done
exit0

UMOUNT ISO FILES:

#!/bin/bash
#
for I in `echo $*`
do
  foo=`gksudo -u root -k -m "enter your password for root terminal
access" /bin/echo "got r00t?"`
sudo umount $I
 done
done
exit0


Backing Up the MBR October 20, 2005

Posted by Carthik in guides, ubuntu.
67 comments

I found myself in the situation of helping a friend reinstall windows on a system which also has Ubuntu on it. In other words, it was a dual boot system, and we were both afraid that re-installing Windows will overwrite the Master Boot Record (MBR) and make it impossible to boot into Ubuntu in the short term. So we devised a plan, with a little help from google to backup his MBR before reinstalling windows, and then restoring it after reinstalling windows.

Create a backup of your MBR by doing a:

$dd if=/dev/hdx of=MBR-backup bs=512 count=1

That should read “create a disk dump of the input file, which is /dev/hdx (change to hda, or hdb or sda, depending on where the MBR is on your computer), and save it in the output-file MBR-backup in the directory from where the command is issued. Backup the first sector only, while you are at it”.

Now that is the backup of your MBR. Restore it later using:

$dd if=MBR-backup of=/dev/hdx bs=512 count=1

Again, change hdx to hda, or hdb or wherever the MBR needs to be restored to. You may have to use a live cd to restore the backup since you will be unable to login to Linux after you reinstall Windows.

As with all other advice, take this with a pinch of salt, and search on google for a solution to your problem, understand the solution and then embark on your mission!

Fix Sound in Firefox for Flash October 20, 2005

Posted by Carthik in snippets, ubuntu.
6 comments

Follow Roel’s instructions here.

‘Nuff Said…

Happy Birthday, Ubuntu!! October 20, 2005

Posted by Carthik in news, ubuntu.
6 comments

It was on October 20th, 2004 that Ubuntu’s Warty (version 4.10) was released. A year has gone by pretty quick, and in a year, Ubuntu has grown from strength to strength – to being the most popular distribution at Distrowatch. Amazing growth, and amazing grace too. So Happy Birthday!!!!, Ubuntu, and congratulations, Mark, and the Ubuntu team – you seem to have a really precocious baby in your hands.

List only the directories October 19, 2005

Posted by Carthik in commands, snippets, ubuntu.
83 comments

I had a trivial problem today where I had a huge list of files in a directory, and other directories within the directory. I was looking for a specific directory and wanted to get the files out of the way. I wanted a listing of the directories within the current directory and nothing more. Luckily, with a little experimentation I was able to figure out how to do this :

$ ls -l | grep “^d”

Neat.

Follow

Get every new post delivered to your Inbox.

Join 244 other followers