Showing posts with label Tweaking. Show all posts
Showing posts with label Tweaking. Show all posts

Wednesday, July 8, 2009

yum/apt-get update Breaks Perl CPAN

Doing an yum update or apt-get update and upgrading your system might break the PERL installation, the output I got while doing so: (after an update).


[root@desktop]# cpan

cpan shell -- CPAN exploration and modules installation (v1.7602)
ReadLine support enabled

cpan> install WWW::Mechanize
CPAN: Storable loaded ok
Going to read /root/.cpan/Metadata
Database was generated on Mon, 15 Jun 2009 02:27:28 GMT
Going to read /root/.cpan/sources/authors/01mailrc.txt.gz
CPAN: Compress::Zlib loaded ok
Going to read /root/.cpan/sources/modules/02packages.details.txt.gz
Database was generated on Wed, 08 Jul 2009 02:28:24 GMT
CPAN: HTTP::Date loaded ok

There's a new CPAN.pm version (v1.9402) available!
[Current version is v1.7602]
You might want to try
install Bundle::CPAN
reload cpan
without quitting the current session. It should be a seamless upgrade
while we are running...

CPAN: LWP::UserAgent loaded ok
Fetching with LWP:
ftp://ftp.jaist.ac.jp/pub/CPAN/modules/03modlist.data.gz
LWP failed with code[500] message[Errno architecture (i386-linux-thread-multi-2.6.18-53.1.14.el5pae) does not match executable architecture (i386-linux-thread-multi-2.6.18-53.el5) at /usr/lib/perl5/site_perl/5.8.8/Errno.pm line 11.
Compilation failed in require at /usr/lib/perl5/5.8.8/i386-linux-thread-multi/IO/Socket.pm line 17.
BEGIN failed--compilation aborted at /usr/lib/perl5/5.8.8/i386-linux-thread-multi/IO/Socket.pm line 17.
Compilation failed in require at /usr/lib/perl5/5.8.8/Net/FTP.pm line 18.
BEGIN failed--compilation aborted at /usr/lib/perl5/5.8.8/Net/FTP.pm line 18.
Compilation failed in require at /usr/lib/perl5/site_perl/5.8.8/LWP/Protocol/ftp.pm line 21.
]
Fetching with Net::FTP:
ftp://ftp.jaist.ac.jp/pub/CPAN/modules/03modlist.data.gz
Can't locate object method "new" via package "Net::FTP" at /usr/lib/perl5/5.8.8/CPAN.pm line 2250.


This is due to the architecture check and differences that PERL encounters on Errno.pm module.

Fix
This can be called a fix or rather a tweak by commenting out these lines (Add #'s to the beginning) on
/usr/lib/perl5/site_perl/5.8.8/Errno.pm


"$Config{'archname'}-$Config{'osvers'}" eq
"i386-linux-thread-multi-2.6.18-53.1.14.el5pae" or
die "Errno architecture (i386-linux-thread-multi-2.6.18-53.1.14.el5pae) does not match executable architecture ($Config{'archname'}-$Config{'osvers'})";

Change the lines to:

#"$Config{'archname'}-$Config{'osvers'}" eq
#"i386-linux-thread-multi-2.6.18-53.1.14.el5pae" or
# die "Errno architecture (i386-linux-thread-multi-2.6.18-53.1.14.el5pae) does not match executable architecture ($Config{'archname'}-$Config{'osvers'})";

Wednesday, June 3, 2009

Resync iPod to new iTunes Library without Erasing or loosing your music

Intro
It is a mess if you reinstall your computer or lost your iTunes library or you want to add a song from your office computer but your iTunes keeps on saying about "Erase and Resync" your library. Erasing and Resyncing is foolish, because you will loose all your favorite songs on your iPod. Follow these steps to resynch iTunes from iPod.

  • Close iTunes if running and Goto the iTunes folder
    (My Documents\My Music\iTunes\ on Windows XP)
  • Clear your current iTunes library by deleting iTunes Library.itl and iTunes Music Library.xml
    Note:This step will erase your iTunes library only not your music files :)
  • Now plug in your iPod and it will be detected as a removable media on Windows.
  • Goto My Computer and open the drive
  • If it is empty, goto Tools > Folder Options > And tick Show Hidden Files and Folders Option
  • Copy the iPod_control folder to any drive on your computer.
  • After copying now run iTunes and press erase and resync.
  • Your iTunes library would be empty so it is okay to resynch.
  • Now unhide the folder you copied over to your drive by right clicking and selecting the properties menu item, and untick the hidden attribute.
  • Start iTunes
  • Drag that folder to your iPod to resync it.
  • TADA, your iPod is resynced with a new iTunes Library

Friday, May 22, 2009

Orkut YouTube Facebook etc Blocked ?? Follow this guide to Unblock

Blocked ??!!!

Most of you may be out there to desparately find out how to unblock all these social networking sites. The solution is to use a proxy. You can use proxy sites available all over the internet, or set up your on SSH proxy if you have an SSH server.

Setting up an SSH server is easy. If you have a machine at home, install any linux distribution with SSH server enabled. Now grab hold of your Home machine IP address and proceed to this page to setup your SSH Proxy.

Alternatively if you don't have the luxury of setting up an SSH machine at home, search on Google "Free Shell Accounts", "Free SSH Accounts", "Free SSH server", etc and sign up with anyone. Beware that your credentials will be passed to these servers while logging in. So it is always secure to use one at your home. Still if you are so desperate, you can do so :D ...

SSH Proxy Setup

Tuesday, March 3, 2009

Reset the root password on a linux box

Intro
The following steps were used to successfully reset the root password of a "Fedora 10" machine. In general, can be applied to any linux machine.


  1. GRUBWhile booting, after the initial splash and POST screen of the bios, the control transfers to GRUB. If there is just one linux operating system installed, the GRUB screen is bypassed to the booting screen, in that case just keep on pressing or tapping the ESC Button until you see the GRUB Menu.
  2. Edit Choose the OS you want to boot into and press "e" to edit.
  3. Edit Find the line that corresponds to kernel, and again press "e". Add the following line to the end of the line.
    single init=/bin/bash

    Then press enter, and then "b" to boot the OS. After booting you will get a root shell.

  4. Mounting the filesystem in readwrite mode: Type in the following command to remount the filesystem in read write mode.
    mount -o remount,rw / 

  5. Not doing this step might give the following error when running passwd, passwd: Authentication token lock busy.
  6. passwd Next just use the passwd command, and give a new root password, Now that's simple.

  7. Reboot or init 5


That's really all I did.

OR from the root shell, you can also edit the /etc/shadow file to remove the password.
OR copy the /etc/shadow /etc/passwd file and use John-The-Ripper software to try cracking the password.

Stuck? Let me know...


.___.__ .__ __ .__ ___. __
__| _/|__| ____ |__|/ |______ | | ______\_ |__ | | __
/ __ | | |/ ___\| \ __\__ \ | | \____ \| __ \| |/ /
/ /_/ | | / /_/ > || | / __ \| |_| |_> > \_\ \ <
\____ | |__\___ /|__||__| (____ /____/ __/|___ /__|_ \
\/ /_____/ \/ |__| \/ \/

a8888b.
d888888b.
8P"YP"Y88
8|o||o|88
8' .88
8`._.' Y8.
d/ `8b.
dP . Y8b.
d8:' " `::88b
d8" 'Y88b
:8P ' :888
8a. : _a88P
._/"Yaa_: .| 88P|
jgs \ YP" `| 8P `.
a:f / \.___.d| .'
`--..__)8888P`._.'

Sunday, July 20, 2008

Server Not Found, Fix DNS Problems.

Sometimes wierd things happen,
Server Not Found www.google.com
Or you can get www.kitiyo.com but not rgb.kitiyo.com
Or you cannot get www.somesite.com but your friend can!
Silly DNS Problems.

When we browser and enter a url in the browser's address bar, one of the first step is to resolve the domain name. ie convert the www.server-name.com to the IP address.

If our dns server settings are wrong or if the dns server does not respond, we get the familiar
Server Not Found page.

There are some ways to resolve this.

  1. Get the correcet DNS IP address from the ISP, and get more than one.
  2. Get some free DNS IP address, some of which are given below
    67.138.54.100
    207.225.209.66
    208.67.220.220
    208.67.222.222
  3. Install a local caching dns server that caches servernames and ip address so that subsequent visits can be made faster since resolving is done locally.
    like Ubuntu debian package dnsmasq


Adding name servers
Windows :

  • Click TCP/IP and then click Properties.
  • Add Primary and Secondary DNS Servers.


Linux:
Add the lines to /etc/resolv.conf
nameserver IP.ADD.RES.SSS
nameserver 67.138.54.100


Any more ideas ?

Thursday, November 29, 2007

Presario V3000 TV settings S-Video PAL

Before starting ...
+ Make sure you have installed Nvidia GeForce Go 6190 drivers.
+ Plugged the TV in via the S-Video Port.

1.
Right click and select Laptop Display from the NVidia Display menu.


2.
Choose the desired option
+ Clone : makes the same screen on your laptop display and on the TV screen.
+ Dual View: makes your TV the extension of your laptop display, ie., the TV together with your laptop becomes a big screen.


+ Apply the changes.

3.
+ If your TV does not work, select the TV, click the Device Settings, Select TV format, Advanced
+ make sure you have put the correct TV output. PAL/B in this case and that
the Video output format as S-video.


Apply changes and you should see the changes on your screen.

:)

Monday, July 30, 2007

Laptop to TV using S-Video Out Port

This post is applicable only to those laptops that are equipped with a S Video Out port (like Compaq Presario V3000 Series). The S-Video Port looks like


S Video port can be used to connect to your TV using a S-Video to RCA Cable. The S Video end of the cable looks like this


You can buy the S-Video to RCA cable, but building it is pretty much simple and costs negligible.

All you have to do is,
connect the Pin 1 and Pin 2 of the connector in S-Video to Ground of RCA
and short the Pin 3 and Pin 4 of S-Video to the Main Pin of RCA.
Some sites recommend using a 470pF Capacitor in shorting the Pin4 to RCA, but i really don't find much of a different when skipping the capacitor. Thus its just a DIY (Do-It-Yourself) project to make your laptop a DVD/CD player or make your TV a secondary monitor screen.

Compaq Presario V3000 Settings
In order to use the S-Video port the NVidia GeForce Go Graphics Drivers must be installed and working.

Don't have an S-Video Port ?
See other options of connecting a laptop to your television

Tuesday, April 17, 2007

Freeing up more disk space

Disk Clean Up
Right Click the drive -> Properties -> Click on the Disk Clean Up -> Press OK


Obsolete Restore Files
Right Click the drive -> Properties -> Click on the Disk Clean Up -> More Options Tab -> System Restore Frame -> Click Clean Up -> OK

Disable Hibernation
If you do not use hibernate feature, disable it.
Control Panel -> Power Options -> Hibernate Tab -> Uncheck Enable Hibernation -> OK


Removing .tmp , .log
.tmp and .log are temporary or log files that simply clog up valuable disk space on your system, Its safe to delete them.

Clean the TEMP directories
X:\Windows\TEMP
X:\Documents and Settings\User\Local Settings\TEMP

Remove unused User Accounts
Delete any users that no longer exists

Change the pagefiling quota on the disk
Control Panel -> Click System -> Advanced Tab -> Performance Frame -> Click Settings -> Advanced Tab -> Virtual Memory Frame -> Click Change Button -> ...


Remove DMP file
Sometimes a RAM image may be saved to your X:\Windows\ folder after a crash. You can remove that files. Normally X:\Windows\memory.dmp

Empty the Trash Bin
Right Click the Recycle Bin and Click empty Recycle Bin.

Related :

Run the Disk Defragmenter to increase performance.
Pressing PrintScreen takes the screen shot of the entire screen.
Pressing Alt+PrintScreen takes the screen shot of the active window only.

Friday, December 29, 2006

Setting up Apache-PHP on windows.

Step 1 : Downloading required files.

apache server binaries : httpd.apache.org
php binaries : www.php.net

Step 2 : Install apache server.
Installing apache server is pretty much simple, and same as any other installation.
Just enter a network domain name and server name and some email id (someone@microsoft.com).
Then choose a installation directory : for reference i am using "C:\".
Note that a directory called apache2 will be created under C:\ .
So "C:\apache2\" is our directory.
Verify your installation by taking your browser and visiting http://127.0.0.1 or http://localhost.
You will see a page that confirms your apache installation.

Step 3 : Configuring apache
Now goto "C:\Apache2\conf\".
Open the file "httpd.conf" in any text editor.
Lines beginning with # are comments .. just read them to know how to tweak apache.
Change the DocumentRoot property to the folder which is the root of the site.

#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "C:/public_html/"

and after that a few lines under ..

#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory "C:/public_html/">

#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs-2.0/mod/core.html#options
# for more information.
#
Options Indexes FollowSymLinks

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
#
AllowOverride None

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all

</Directory>

So C:\public_html\ is the server root. ie http://localhost/ = C:\public_html.
After this is done test the configuration by executing (command line):

C:\Apache2\bin>apache -t

If the syntax is right you will get a "Syntax OK" message.

Step 4 : Installing php
To install php, just extract or copy the "PHP" folder to C:\Apache2\ so that C:\Apache2\PHP is created.

Step 5 : configuring PHP
Copy the "php.ini-recommended" file from C:\apache2\php\ to C:\apache2\
Rename it to "php.ini".

Add 2 lines to the end of the file httpd.conf:


LoadModule php5_module C:/apache2/php/php5apache2.dll
AddType application/x-httpd-php .php


Test the php installation by making a php file.

test.php

<?php
phpinfo();
?>


Access the test.php (http://localhost/test.php) from your browser. If you see the source code, installation has failed.
If you see the php info file . PHP installation was successful.
Test the apache server configuration (mentioned above) to find out the error.

Stuck ? leave a comment...

Friday, December 15, 2006

about:config on firefox

This one is for those using Mozilla Firefox, if you are using take a new page or new tab and on the address bar type in about:config. You can do all the tweaking of Firefox from this page. about:config

You can edit the values by double clicking and changing the value on the dialog box or Right Click to Add/Modify etc.

Warning!
You can mess up firefox if you do editing. So always backup the values before tweaking.
Take File > Save Page.

Some examples:
browser.startup.homepage [String]
Sets your home page.

security.dialog_enable_delay [Integer] [in milliseconds]
Specifies the number of milliseconds till the button is enabled. You see this normally in download dialog boxes, in which the download button is enabled only sometime after. This is a security measure.

view_source.editor.external [True/False]
True enables another external editor to view the source.

view_source.editor.path [String]
External editor path.

browser.cache.memory.capacity [Integer]
This saves memory usage, by limiting the memory, and fixes memory leak.

Something you tweaked? Please leave a comment...

Related:

about:mozilla
about:plugins
about:credits
about:license
about:cache
about:buildconfig