Sunday, September 16, 2012

Wine - Creating 32bit WINEPREFIX


From default wine installation I was on 64 bit wine. Due to some requirement had to switchover to 32bit wine arch.

Following is what I did as the current user -

#rm -rf ~/.wine
#WINEARCH=win32 winecfg



Wednesday, September 12, 2012

Cannot start mysqld (Fatal error: Can't open and lock privilege tables: Incorrect file format 'host' )


Are you seeing - Fatal error: Can't open and lock privilege tables: Incorrect file format 'host' ?


Following is what I did -
  • removed mysql-server (#yum remove mysql-*)
  • re-installed mysql-server (#yum install mysql-server)
  • #cd /var/lib/mysql/mysql
  • #rm -rf *
  • #mysql_install_db
and then,

#service mysqld start


It worked!



Tuesday, September 11, 2012

Windows 7 USB install error (Setup was unable to create a new system partition or locate an existing system partition)


Error: "Setup was unable to create a new system partition or locate an existing system partition. See the Setup log files for more information"

Are you are seeing this error (above) while trying to install Windows 7 from a bootable USB?

Now what you are going to do is this -> after booting and selecting the language, but before clicking the "Install" button, remove the USB drive, wait a second, then reinsert it.

Then continue as you were thinking it would go.

Hope I helped you today!


Thursday, September 6, 2012

Best SCP GUI on Linux



For the impatient

  1. Look no where else if you already have nautilus file manager
  2. For best view/performance setup nautilus in browser mode [ edit -> preferences -> behavior (tab) -> behavior (section) -> check "Always open in browser windows" ]
  3. "sftp://user@machinename" in the address bar and you are all set ;)


For the rest

Till I found sftp with nautilus I also came across some reads on fish for Konqueror


Tuesday, September 4, 2012

Blogger - How to remove Navbar


Taken from - http://blogger-hints-and-tips.blogspot.in/2012/07/close-the-gap-left-when-Bloggers-navBar-is-removed.html

You can move the header up to cover over the area where the nav-bar was by adding a CSS rule to your template in the normal way.

The rule to add is:
#navbar { height: 0px; visibility: hidden; display: none;}

Apply that, and the space that the nav-bar was in will simply close up, so the rest of the content is a little closer to the top of the screen.

Monday, September 3, 2012

Install Firefox 15 on Fedora 17/16, CentOS/Red Hat (RHEL) 6.3



Mozilla Firefox 15 is released and this is guide, howto install Firefox 15 on Fedora 17/16/15/14, CentOS 6.3/6.2/6.1/6 and Red Hat (RHEL) 6.3/6.2/6.1/6 using YUM. Firefox 10 is currently available on CentOS 6.3/5.8 and Red Hat (RHEL) 6.3/5.8 own repos, so with this guide you can also install Firefox 10 on CentOS 5.8 and Red Hat (RHEL) 5.8.

What’s new in Firefox 15

  • Silent, background updates
  • Support for SPDY networking protocol v3
  • WebGL enhancements, including compressed textures for better performance
  • Optimized memory usage for add-ons
  • Native support for the Opus audio codec added

What’s new in Firefox 10

  • Most add-ons are now compatible with new versions of Firefox by default
  • The forward button is now hidden until you navigate back
  • Anti-Aliasing for WebGL is now implemented
  • CSS3 3D-Transforms are now supported
  • New bdi element for bi-directional text isolation, along with supporting CSS properties
  • Full Screen APIs allow you to build a web application that runs full screen
  • Added IndexedDB APIs to more closely match the specification
  • Inspect tool with content highlighting, includes new CSS Style Inspector
Read full details from Firefox 15 release notes and Firefox 10 release notes.

Install Mozilla Firefox 15/10 on Fedora 17/16/15/14, CentOS 6.3/6.2/6.1/6/5.8 and Red Hat (RHEL) 6.3/6.2/6.1/6/5.8

1. Backup your current Firefox 3/4/5/6/7/8/9/10/11/12/13/14 profiles (just in case)

tar -cvzf $HOME/mozilla-firefox-profiles-backup.tar.gz $HOME/.mozilla/firefox/

2. Change root user

su -
## OR ##
sudo -i

3. Install Remi repository

Note: Currently not needed on Fedora 17, Fedora 16, CentOS 5.8 and Red Hat (RHEL) 5.8.

Fedora 15/14

## Remi Dependency on Fedora 15 ##
rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm 
rpm -Uvh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
 
## Fedora 15 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-15.rpm
 
## Fedora 14 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-14.rpm

CentOS 6 / Red Hat (RHEL) 6

## Remi Dependency on CentOS 6 and Red Hat (RHEL) 6 ##
rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-7.noarch.rpm
 
## CentOS 6 and Red Hat (RHEL) 6 ##
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

4. Check Available Firefox versions

Fedora 17/16

yum list firefox

Fedora 15/14, CentOS 6.3 and Red Hat (RHEL) 6.3

yum --enablerepo=remi list firefox

CentOS 5.8 and Red Hat (RHEL) 5.8

yum list firefox
Note: Firefox 10 available.

5. Update or Install Mozilla Firefox 15/10

Fedora 17/16

yum update firefox
## OR ##
yum install firefox

Fedora 15/14, CentOS 6.3 and Red Hat (RHEL) 6.3

yum --enablerepo=remi update firefox
## OR ##
yum --enablerepo=remi install firefox

CentOS 5.8 and Red Hat (RHEL) 5.8

yum update firefox
## OR ##
yum install firefox
Note: Firefox 10 available.

6. Start Firefox 15/10

Then start Firefox with using command:
firefox
Or use Firefox (15/10) launcher.

What can I do with CentOS ?


Index

  1. I want to install EPEL repository
  2. How to mount 'ntfs' partition in CentOS?
  3. How do I create CentOS local repository?
  4. Create local yum repository
  5. Setting up passwordless SSH
  6. Install firefox 15 on CentOS
  7. Download rpm packages locally to a directory to setup local repo
  8. Install VirtualBox on CentOS

1. I want to install EPEL repository

For the impatient
I am using CentOS 6
For the rest
Go to  http://wiki.centos.org/AdditionalResources/Repositories it contains the additional repositories.
Find your favourite repository/EPEL and follow the links, they should have updated information over time.

2. How to mount 'ntfs' partition in CentOS?

Read the guide here - http://wiki.centos.org/TipsAndTricks/NTFS

3. How do I create CentOS local repository?

For the impatient
I am using CentOS 6

  • yum install createrepo
  • createrepo /path/to/rpms

 

4. Create local yum repository

For the impatient
I am using CentOS 6
  • Should have createrepo package. If not then yum install createrepo
  • Create a repository directory that will contain rpms (mkdir /media/repo)
  • #createrepo /path/to/rpms (here /media/repo)
  • #nano /etc/yum.repos.d/local.repo
  • Contents of local.repo
[local]
Name=CentOS 6.3 $releasever $basearch local repository
baseurl=file:///media/repo
enabled=1

Follow the guide here - http://adhocshare.blogspot.in/2012/08/create-your-own-local-yum-repositories.html

5. Setting up passwordless SSH

For the impatient
I am using CentOS
  • #ssh-keygen -t rsa
  • #ssh-copy-id -i ~/.ssh/id_rsa.pub root@hostname

 

6. Install firefox 15 on CentOS

For the impatient
I am using CentOS
For the rest
Follow here - http://adhocshare.blogspot.in/2012/09/install-firefox-15-on-fedora-1716.html  

 

 

7. Download rpm packages locally to a directory to setup local repo

For the impatient
I am using CentOS
  • Install yum-downloadonly plugin (#yum install yum-downloadonly)
  • Only download -> #yum install firefox --downloadonly --downloaddir=/media/repo
  • Download and install -> #yum install firefox --downloaddir=/media/repo
For setting up local repository go to section 4.

8. Install VirtualBox on CentOS

For the impatient
I am using CentOS

  • from directory /etc/yum.repos.d run #wget http://download.virtualbox.org/virtualbox/rpm/rhel/virtualbox.repo
  • #yum groupinstall "Development Tools"
  • #yum install kernel-devel
  • #yum install VirtualBox-4.2
  • for a user who wants to run virtualbox run #usermod -a -G vboxusers username

For the rest - goto http://wiki.centos.org/HowTos/Virtualization/VirtualBox

 

 

Thursday, August 30, 2012

How to Change the Hostname on Linux CentOS 6.3 Server




In this post, i will show you on how to change the Hostname on linux CentOS 6.3. I have tested this on RHEL 6, CentOS 5.5 and CentOS 6.2.  and Centos 6.3. Reboot is required for both options (A) and (B) for the changes to take effect.

Check current hostname with this command :
# hostname --fqd
centos62.ehowstuff.local
Option A:
1. Modify /etc/sysconfig/network
# vi /etc/sysconfig/network
2. Edit to your preferred hostname :
NETWORKING=yes
 
HOSTNAME=server.vjetnamnet.local
3. Modify /etc/hosts file as below :
# vi /etc/hosts
 
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
 
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
 
192.168.1.44 server.vjetnamnet.local server
4. Save and reboot your server.
Option B:
1. Type the following command to enter GUI mode.
# system-config-network
2. Go to “DNS Configuration”.
3. Modify your preferred hostname and click OK.
4. Click ” Save & Quit”.
5. Modify /etc/hosts file as below :
# vi /etc/hosts
 
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
 
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
 
192.168.1.44 server.vjetnamne.local server
6.Reboot your server.