28
Nov
09

Desktop background as xsplash / gdm in Ubuntu Karmic 9.10

(Before running this script take a backup of the default background file located at /usr/share/images/xsplash)

Depends on:
- xsplash (default on ubuntu karmic)
- imagemagick
Install imagemagick:

sudo apt-get install imagemagick

Download the script from here

1. Unpack wallpaper_daemon.py, store it anywhere you like (e.g. ~/.scripts) and make it executable:

chmod +x wallpaper_daemon.py

2. Run

./wallpaper_daemon.py --install

3. Add wallpaper_daemon.py to the startup programs (gnome-session-properties).

4. restart

Test it (without restarting)

sudo xsplash

14
Sep
09

[MPlayer] Turkish Encoding Problem

Solved:
1- (In MPlayer) go to PREFERENCES / SUBTITLES & OSD section;
for ENCODING select TURKISH
2- Do not select UNICODE SUBTITLE at the same page.
3- Go to FONT section;
for ENCODING select UNICODE.
4- Restart MPlayer.

Voilà!

31
Mar
09

ifconfig command

NAME

ifconfig – configure a network interface

SYNOPSIS

ifconfig [interface] 
ifconfig interface [aftype] options | address …

DESCRIPTION

Ifconfig is used to configure the kernel-resident network interfaces. It is used at boot time to set up interfaces as necessary. After that, it is usually only needed when debugging or when system tuning is needed.If no arguments are given, ifconfig displays the status of the currently active interfaces. If a single interface argument is given, it displays the status of the given interface only; if a single -a argument is given, it displays the status of all interfaces, even those that are down. Otherwise, it configures an interface.

Continue reading ‘ifconfig command’

31
Mar
09

route command

NAME

route – show / manipulate the IP routing table

SYNOPSIS

route [-CFvnee]

route
[-v] [-A family] add [-net|-host] target [netmask Nm] [gw Gw] [metric N] [mss M] [window W] [irtt I] [reject] [mod] [dyn] [reinstate] [[dev] If]
route
[-v] [-A family] del [-net|-host] target [gw Gw] [netmask Nm] [metric N] [[dev] If]
route
[-V] [--version] [-h] [--help]

DESCRIPTION

Route manipulates the kernel’s IP routing tables. Its primary use is to set up static routes to specific hosts or networks via an interface after it has been configured with the ifconfig(8) program.

When the add or del options are used, route modifies the routing tables. Without these options, route displays the current contents of the routing tables.

Continue reading ‘route command’

31
Mar
09

“Linus Torvalds” One of the Greatest Men Alive?

 

by Daniel Pop-Silaghi

Given the recent release of Linux kernel 2.6.29 and the ever-growing number of new Linux users, we thought it would be nice to talk a little about the man that started it all: Linus Torvalds.

Being 39 years of age, Linus Torvalds was born on the 28th of December 1969 in Helsinki, Finland. Though the fact that he graduated the Helsinki University with a Master’s degree in computer science may not seem very interesting, you should know that the University’s decision to hold a UNIX course during his years there was one of the things that led to the creation of Linux.

The course convinced Linus that UNIX was the best operating system out there and made him frantically look for a copy. Not having any luck, he eventually had to buy a cheap, standard 386 architecture PC that had MINIX pre-installed. Being a newsgroup addict, Linus hated MINIX’s poor terminal emulation, a must for news reading, and wanted to write a new terminal emulation package. In the meantime, getting his hands on a book that covered all of 386’s new exciting features (memory management, paging, segmentation, task switching, etc.), Linus was eager to test out every capability for himself, mainly for self-teaching purposes. That, combined with the realization that creating a terminal emulator involved many other things, was the key element that pushed Linus Torvalds into taking the decision, back in the summer of 1991, to write a new operating system: Linux. There were, of course, other outside factors that created perfect conditions for that to happen, including the accessible education in Finland and the fact that he lived with his parents for quite a while, allowing him to concentrate mainly on Linux and not worry about a job. Accidentally erasing his MINIX partitions was another favorable factor, as he had to take a decision whether or not to repeat the long process of reinstalling and reconfiguring it or just concentrate on making Linux really usable and self-sufficient. He obviously chose the latter and was thus motivated to not let the project die. Linus Torvalds then released the code on the Internet and the project grew and grew to what it is today, with thousands of people contributing.

Continue reading ‘“Linus Torvalds” One of the Greatest Men Alive?’

09
Mar
09

Converting (Red Hat) .rpm packages into (Debian) .deb packages

Alien is a method for converting (Red Hat) .rpm packages into (Debian) .deb packages. It is not reliable and converted packages must be tested extensively for functionality, with line changes often required. It is often more reliable to create (Debian) .deb packages from source, and even the Alien software maintainers do not recommend using Alien for important packages. To keep alien from changing the version number, use the following command

alien -k rpm_file_name.rpm

Convert the package.rpm into a package.deb

alien -d package-name.rpm

Convert the package.rpm into a package.deb, and install the generated package

alien -i package-name.rpm

To convert .rpm to debian

sudo alien -k *.rpm
08
Mar
09

Mounting NTFS Partitions (with read/write privileges)

Install NTFS-3G, the NTFS manager:

sudo apt-get install ntfs-3g

Note: You should also be a member of the fuse group to use ntfs-3g.

Find out the name of your ntfs partition:

sudo fdisk -l

Method 1: In this example, the NTFS drive is listed by fdisk as /dev/sda2, but yours may differ.

Make a mount point for the drive:

sudo mkdir /media/WindowsNTFS

Edit fstab:

sudo nano /etc/fstab

Comment out the automatically added lines by Ubuntu installation:

#/dev/sda2  auto nouser,atime,noauto,rw,nodev,noexec,nosuid 0 0
#/dev/sda2 /mnt auto user,atime,noauto,rw,nodev,noexec,nosuid 0 0

and instead add the line:

/dev/sda2 /mnt/WindowsNTFS ntfs-3g quiet,defaults,rw 0 0

Note: There are many ways to mount the drive, depending on your needs. The fstab file controls this process. See How to edit and understand fstab and Intro to using fstab.

In this example, I indicated that the file system was an ntfs-3g filesystem, so did not use the auto option (which detects the filesystem automatically). I used rw to specify read/write privileges for all users, but umask=0 and umask=000 are accepted by some kernels.

08
Mar
09

Create a symlink from a file to another location

ln -s /path/to/source /path/to/destination

If /path/to/destination require superuser rights, use:

sudo ln -s /path/to/source /path/to/destination

This is similar to, but more powerful than, creating Shortcuts, with which former Windows users may be familiar.

08
Mar
09

Handling (Tar/GZip) and (Tar/Bzip2) Archives

(Tar/GZip) archives end in “.tar.gz” and (Tar/Bzip2) archives end in “.tar.bz2″. Bzip2 is the newer, more efficient compression method. These files can generally be automatically extracted by merely clicking on them from your file manager (Nautilus), since file associations with the appropriate archival utilities are set by default in Ubuntu. These instructions are for those who wish to use the command line Terminal.

Continue reading ‘Handling (Tar/GZip) and (Tar/Bzip2) Archives’

06
Mar
09

2 Columns CSS Template

CSS Code

#wrapper {
	text-align: left;
	margin: 0px auto;
	padding: 0px;
	border:0;
	width: 600px;
	background: url("/path/to/your/background_cols.gif") repeat;
}

#header {
	margin: 0 0 15px 0;
	background: yellow;
}

#side-a {
	float: left;
	width: 150px;
}

#side-b {
	margin: 0;
	float: left;
	width: 450px;
	height: 1% /* Holly hack for Peekaboo Bug */
}

#footer {
	clear: both;
	background: #A2A2A2;
}

HTML Code

<div id="wrapper">
	<div id="header">
		HEADER
	</div>
	<div id="container">
		<div id="side-a">
			SIDE A
		</div>

		<div id="side-b">
			SIDE-B
		</div>
	</div>
	<div id="footer">
		FOOTER
	</div>
</div>