Tuesday, March 30, 2010

Reset or Change Root password in Fedora

Forget root password on Fedora ? need to reset or change the root password on Fedora 10 ? Please note that start from Fedora 10, you may no longer allow login as root user on Fedora 10 ... then you may not need to follow this step by step article to reset and change root password on Fedora 10.  To change the root password, this step by step article going to guide you to enter the runlevel 1 or single user mode and then change the root password on your Fedora 10 system using the passwd command... but if you still insist to log in as root on Fedora 10, this step by step article on login as root on Fedora 10 might be useful.

Step by step change root password:

1.  Boot up your Fedora 10 system, on the boot up splash screen press and hold shift key until you enter the GRUB screen as show on figure below
figure show Fedora 10 boot screen, press and hold "shift" key here and wait until GRUB boot menu screen appear

2.  figure show Fedora 10 GRUB boot menu screen, if you have multiple operating system installed, you may have to select the Fedora 10 as show on figure below by using the 'up' and 'down' key... then hit the 'e' key to enter GRUB editing mode

3.  Use the 'up' and 'down' key again, select the 'kernel /vmlinuz-2.6.27.5-117.fc10.i686 ro root=UUID=27f6ac23-638f-439a-8a97-2baaf6a32922 rhgb quiet', and the hit the 'e' key again to edit the grub command line.

4.  The below screen appear after you hit the 'e' key, now notice that you mouse cursor at the end of line 'kernel /vmlinuz-2.6.27.5-117.fc10.i686 ro root=UUID=27f6ac23-638f-439a-8a97-2baaf6a32922 rhgb quiet'.

5.  Change at the end of the line that say 'rhgb quiet' to 'linux single' as show on the example below.
From : kernel /vmlinuz-2.6.27.5-117.fc10.i686 ro root=UUID=27f6ac23-638f-439a-8a97-2baaf6a32922 rhgb quiet
To    : kernel /vmlinuz-2.6.27.5-117.fc10.i686 ro root=UUID=27f6ac23-638f-439a-8a97-2baaf6a32922 linux single
hit 'Enter' key after finish enter the 'linux single' at the end of kernel line, as show on GRUB screen above.

6.  Hit the 'b' key to boot the selected kernel and start the boot process to Linux single user mode.

7.  After you hit the 'b' key, the Fedora 10 should reboot and then enter the single user mode and should give you root shell terminal without prompt any password field or ask for password.  The example below show the single user terminal screen.
Remounting root filesystem in read-write mode :
Mounting local filesystems :
Enabling local filesystem quotas :
Enabling /etc/fstab swaps :
[root@fedora /]#

Change root password


   Issue passwd command to change root user password on Fedora 10 after we finish the procedure to enter the Linux single mode as show on step by step example above.
change password, change root password fedora 10
[root@fedora /]# passwd                           <-- Start type in 'passwd' command and hit Enter key
Changing password for user root.
New UNIX password:
BAD PASSWORD: it is too simplistic/systematic
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
[root@fedora /]#

Then reboot the system and start using the new root password for your Fedora 10 system
[root@fedora /]# reboot                           <-- Type in 'reboot' command and hit Enter key to start reboot Fedora system

Note:   To verify your new root password please login as normal user and execute the 'su -' command on the shell terminal, then enter the new Fedora 10 password when ask.

Trouble shoot:


   If message say that 'passwd: Authentication token lock busy' display when you execute passwd command to change root password, execute command below to remount the system:
[root@fedora /]# mount -o remount, rw /                           <-- Then hit the Enter key
Execute the password command again:
[root@fedora /]# passwd 
Then reboot the system
[root@fedora /]# reboot

Thursday, March 25, 2010

Update All Default Players in Linux and Install More Players

Even though there are lot of players in linux, we can play anything with those players. So how can we make those players to play our songs like mp3. Here are the commands to update all the players....
  1. su -c 'rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
    http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm'
  2. yum update @sound-and-video
  3. yum install xine-lib-extras-freeworld
  4. yum install gstreamer-plugins-ugly
  5. yum install phonon-backend-xine
  6. yum install phonon-backend-gstreamer

Install Internet Explorer in fedora

I know what you're saying, why would I ever want Internet Explorer installed on my perfectly good Linux system? If you don't have your own answer to that question, feel free to just skip this section. For everyone else, it's actually quite easy thanks to some very handy scripts from IEs4Linux. Before you start you'll need to make sure you have wine and cabextract installed:
# yum -y install wine cabextract
Then just download the latest script, extract and run it. The example below is based on version 2.0.5, just adjust the version number as necessary. Please note that you will want to install and run this as your own user, NOT as root. I used the defaults except that I installed all the versions of IE. I do some web development and I always find myself needing to resolve some goofy incompatibilites with older versions of IE.

$ gtar xzvf ies4linux-2.0.5.tar.gz
$ cd ies4linux-2.0.5
$ ./ies4linux
Welcome, greg! I'm IEs4Linux.
I can install IE 6, 5.5 and 5.0 for you easily and quickly.
You are just four 'enter's away from your IEs.

I'll ask you some questions now. Just answer y or n (default answer is the bold one)

IE 6 will be installed automatically.
Do you want to install IE 5.5 SP2 too? [ y / n ] y
 .
 .
 .
IEs 4 Linux installations finished!

To run your IEs, type:
 ie6
 ie55
 ie5
You can read more about this feature on my Internet Explorer with ActiveX on Linux page. It goes into a little more detail about using IE on Linux.

How to Install Audio & Video Players in Linux

Before you add repositories it's probably a good idea to make sure your system is fully updated first. At this point I'm prefering the Livna repository as it's the most useful and complete but at some point I might need to add another one for things that are lacking there. The easiest way to get started is to install the livna-release packages:


# rpm -ihv http://rpm.livna.org/livna-release-8.rpm

Install MP3 Plug-in

Since you've been following along this next step is about as easy as it gets. Just use yum  to automatically install the MP3 plug-ins for xmms and Rhythmbox like this:

# yum -y install xmms xmms-mp3 xmms-faad2 gstreamer-plugins-ugly \
 gstreamer-plugins-bad libmad libid3tag
While you're here you might as well install my personal favorite (this week at least) music player Banshee:

# yum -y install banshee
The -y  flag is to automatically answer yes to any question.  If you want to be able to say no you can ignore that flag.  While you're there I highly recommend the grip CD ripper which supports both MP3 and Ogg formats.  Once again installation is quite simple:

# yum -y install grip

Install DVD player

Currently I find the DVD player that works best is the Xine Multimedia Player which is found in the Livna repository so installing it is just this simple:

# yum -y install xine xine-lib xine-skins xine-lib-extras-nonfree libdvdcss

This will install the xine DVD/VCD/CD player.
Now to get xine to automatically play a DVD upon insertion instead
of the Totem player which can't actually play DVDs, you can simply
use the gconftool-2 utility as follows:

$ gconftool-2 --set /desktop/gnome/volume_manager/autoplay_dvd_command \
'xine --auto-play --auto-scan dvd' --type='string'


Install MPlayer Media Player

At some point you're probably going to want to play a QuickTime, AVI or ASF file so you'll want the MPlayer media player. Fortunately with the FreshRpms repositories it's also very easy to download and install. Then you can go ahead and install mplayer and all it's dependencies:

# yum -y install mplayer mplayer-gui mplayer-skins mplayer-fonts mplayerplug-in
 
This command line will download the whole kit and kaboodle, command line
utilities, plug-ins, etc.
If you want to play content from a command line you will want to use
the gmplayer  version which will include
a skin-able control panel.
Restart your web browser after that whole mess is done installing and
you'll also have a plug-in for Mozilla so you can play embedded content.
While you're at it be sure to configure mplayer
to use the Pulse sound system rather than the default.  It just works better.

Edit the file ~/.mplayer/config and add the following line:
ao=pulse
You can enable support for mms streaming by opening Firefox and click on the special URL about:config. Right click on the list and choose New then choose String. For the preference name enter network.protocol-handler.app.mms then for the string value enter gmplayer.
Special 64-bit instructions:
The above installs the 64-bit version of everything but because your other plug-ins are 32-bits you need to run the 32-bit version of Firefox, which won't be able to use the 64-bit version of the plug-in you just installed. The plug-in can use the 64-bit version of the mplayer application just fine so all you need to do then is to install the 32-bit mplayerplug-in plus a dependency it requires. If you know of any easier way to do this please let me know below.
# rpm -ihv http://ftp.freshrpms.net/pub/freshrpms/fedora/linux/7/mplayerplug-in/mplayerplug-in-3.40-1.fc7.i386.rpm And finally you'll probably also want some additional codecs to play all that proprietary video that seems to have infected the Internet. Go to the MPlayer Download page and find the Binaries Codec Package section then follow the link for codecs directory. There you will grab the latest all codecs file. You'll need to install those files in /usr/local/lib/codecs. Here are the steps. Remember the exact file names may change at some point. If you also installed xine you will need a symlink since it expects codecs to be in a different directory. # gtar xjvf all-20071007.tar.bz2 # mv all-20071007/* /usr/local/lib/codecs # ln -s /usr/local/lib/codecs /usr/lib/codecs # ln -s /usr/local/lib/codecs /usr/local/lib/win32


Install VLC (VideoLAN Client)

Multimedia can be the achilles heel of Linux, but with just a little work you should be able to play just about anything your friends can. Besides Mplayer the other great video player is called VLC. It too is trivially easy to install once you have your repositories set up:

# yum -y install vlc
Once the client and a zillion dependencies get installed you can play a huge variety of video formats easy with the command vlc 

Install RealPlayer 10 Media Player

This one is a little tricky only because the latest official release is horribly out of date and doesn't even use ALSA for sound. So rather than deal with annoying workarounds I think the easiest thing to do now is to just use the latest daily build that's available. I'm currently using RealPlayer-10.1.0.3114-20070503.i586.rpm which you can just download and install. This one pretty much "just works" and doesn't seem to have any bugs I can see.
Just install it:

$ rpm -ihv RealPlayer-10.1.0.3114-20070503.i586.rpm
Then whenever you want to view something just use /usr/bin/realplay. Here is a link to a cute test video to make sure it's working for you.  If you also installed Mplayer above then you will likely run into a problem where the Mplayer provided Real Media plug-in will be run instead of the one installed by the RealPlayer package.  The mplayer verison of the plug-in does not work correctly in most cases and causes more problems than it solves.  The only way I've found to get rid of it is to just simply delete the plug-in files:

# cd /usr/lib/mozilla/plugins
# rm mplayerplug-in-rm.*
You'll of course need to do that again should you re-install or upgrade the mplayer plug-ins.





How to Install exe files in linux like windows through wine

There is a great possibility to install .exe files in liux, like in windows.

Wine is a program which helps to do the process of installation.

use the following methods to to do it

1. login as su
2. then type yum install wine

After installlation of wine,  you are free to install any .exe files.

Install WireShark Network Analyser in Fedora

Wireshark is the famous tool for capturing packets, analyzing the network.

To install it in Redhat Linux

First check the dependecies exists or not

yum search wireshark

if it exists then install it using the following command


yum install wireshark-gnome


To read More about wireshark go to 

http://www.wireshark.org/ 

Install vlc in fedora 12

Its very easy to install VLC 1.0.3 or any new version of vlc in Fedora 12 ( Constantine).
These are simple three steps you have to write in the Terminal of Linux.
Opening the terminal :-
System Tool – Terminal open it and paste the below three commands one by one..

su root
rpm -ivh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
 
yum install vlc

Saturday, March 20, 2010

Fedora 10 Rar and Unrar

By default, Rar is not available in Fedora 10. If all you need to do is extract files from a Rar archive, unrar from RPM Fusion's YUM repositories will work. If you need to create Rar archives, then you will have to download and install the complete Rar package from DAG. The instructions below show you how.

Only Need to Extract Files?

First, install RPM Fusion's free and nonfree YUM repositories. For detailed information about installing RPM Fusion, see: http://rpmfusion.org/Configuration

su -c "rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm"
su -c "rpm -Uvh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm"

Next, install the unrar packages from RPMFusion's nonfree repository.

su -c "yum install unrar"

Done! You now have unrar in /usr/bin/unrar. This binary can only extract files from Rar archives. Use this command to see all available options:

/usr/bin/unrar -?

Need to Create Rar Archives?

First, download the source RPM from DAG: http://dag.wieers.com/rpm/packages/rar

wget -c http://dag.wieers.com/rpm/packages/rar/rar-3.5.1-1.rf.src.rpm

Now, install the source RPM. This will create a $HOME/rpmbuild tree. Please
note that you do not need to be root.

rpm -iv rar-3.5.1-1.rf.src.rpm

Next, build a binary package in $HOME/rpmbuild. Again, no need to be root.

rpmbuild -bb ~/rpmbuild/SPECS/rar.spec

Finally, install the built RPM as root:

su -c "rpm -Uvh $HOME/rpmbuild/RPMS/$(arch)/rar-3.5.1-1.rf.x86_64.rpm"

Done! You now have rar in /usr/bin/rar. This binary can build and extract Rar files. Use this command to see all available options:

/usr/bin/rar -?

Friday, March 19, 2010

Network Problem in fedora

Older versions of fedora used the network service to control network cards. Each card had a config in /etc/sysconfig/network-scripts called something like ifcfg-eth0 for eth0 and so on. Apparently starting the old network service conflicts with starting NetworkManager. So, to fix this problem, do the following:


Code:
$ su -
# cd /etc/sysconfig/network-scripts
# ls
See if there are any config files for your network cards in here, such as ifcfg-eth0. Move each of them to a backup, such as:

Code:
# mv ifcfg-eth0 ifcfg-eth0.bak
Turn off the old network service, and turn on NetworkManager:

Code:
# chkconfig network off
# chkconfig NetworkManager on
Reboot the system.

This assumes that you have all the right packages installed. It also means that the network may come up later in the boot sequence. If you have things like ntpd or are mounting nfs disks I'm not sure how this affects that stuff. If you had static IP addresses setup this might cause you to have to reconfigure them. Once you get it working this way, you can move the ifcfg- files back, and I think NetworkManager should give you the option to use that configuration ("System eth0" or the like).

How to Copy flash or html Embedded videos

Saving Flash files from Firefox


Firefox for Newbies
a. Click Tools - Page Info
b. Click the Media Tab on the Page Info Windows
c. The media tab has a complete list (with preview) of Images, CSS Files and Shockwave Flash files that were downloaded by the Firefox browser while rendering (loading) the page.
d. Scroll down the list and locate the swf file.
e. Click the "Save As" button. Select some directory on your hard drive and save the file (No need for a third-party plug-in)

Firefox for Geeks and Power Users
a. Type about:blank in the Firefox address bar
b. Now click List cache entries or directly type about:cache?device=disk (Disk cache device)
c. Press Ctrl+F and try to location the flash file by typing some part of website URL or the flash file name or just .swf. After some hit and trial, you should be able to locate the swf file URL
d. Click the SWF URL to open the Cache Entry Information page. Right click on the link and choose "Save link as"

How to save flash in IE browser


a. Click Tools - Internet Options
b. In the General Tab, click the Settings button available in the Temporary Internet Files group.
c. Click View Files to open your Temporary Internet Files folder. Depending upon your IE settings, the Temp. folder can contain tens of thousands of files.
d. Click View - Details. Now click View - Arrange Icons By - Internet Address. Depending upon the webpage, there could one or more Flash files (Shockwave Flash Object) under the Inernet Address.
e. Once you find the right flash file, right-click and choose Copy. Then paste the swf file in any other directory. Be sure to
keep the page and IE open to avoid purging of the cache file.

For newbies, I suggest the following approaches:
1. Get a download accelerator like Flashget and tell it to automatically download the shockwave extention (*.swf)
2. Or download a free IE plug-in for saving flash files.

How to save Flash files from Opera or Google Chromebrowser
Just like IE, these browsers store the flash files in the browser cache.