All posts by DJS

Using parted on > 2TB drives to create new partitions for LVM

fdisk utility doesn’t support storage device that is larger than 2TB. Therefore you need to use GNU “parted” to create your partition.

As root run ‘parted /dev/sdX’ where X is the SAS/SATA/whatever controller’s drive as presented to the Linux kernel.

At the ‘(parted)’ prompt, enter:

mkpart primary ext3 0 -1
set 1 lvm on

Then ‘quit’ Parted to save your changes to the partition table on the relevant drive.

This creates a new partition assigned the whole drive capacity and gives it the LVM partition type, then saves those changes & exits parted.

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

How to install WildCard SSL in cPanel

Install the SSL Server Certificate Files

  1. Login to cPanel
  2. Click SSL/TLS Manager > Certificates (CRT) > Generate, view, upload or delete SSL certificates
  3. In the Upload a New Certificate section click the Browse button and locate your SSL Server Certificate file your_domain_com.txt.
  4. Click the Upload button.
  5. Click the Go Back link to return to SSL/TLS Manger.

Setup the Domain

  1. Click SSL/TLS Manager > Setup a SSL certificate to work with your site. If this option is not available to you your ISP may have disabled it and you will need to contact them to complete your SSL setup.
  2. From the Domain drop down menu select the domain that will use the SSL Certificate. The system will attempt to Fetch the SSL Certificate and corresponding private key.
  3. Open SSL_Intermediate.txt in Notepad or other simple text editor (not Word). Copy-and-paste all the contents of the GeoTrust_Intermediate.txt file into the Ca Bundle (CABUNDLE) box.
  4. Click on Install Certificate. You should receive a message that the certificate was successfully installed. If you receive an error you may need to contact your web hosting provider for additional support.

How to set your subdomain SSL

  1. Open public_html/.htaccess and add the following code

    RewriteCond %{SERVER_PORT} ^443$
    RewriteCond %{HTTP_HOST} ^abc\.domain\.com$ [NC]
    RewriteCond %{REQUEST_URI} !^/abc/
    RewriteRule ^(.*) /abc/$1

    /abc/ is your subdomain folder under public_html.

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

Recreate deleted ‘www’ symbolic link in cPanel

If you accidentally remove the ‘www’ shortcut to public_html folder in cPanel, please follow tutorial below to recreate it.

1) Go to cPanel user folder

cd /home/user/

2) Create back the symbolic link

ln -s public_html www

3) Change the ownership of the www sym link to the cPanel user’s ownership

chown -h user.user www

4) Done. Do a ls -al to double check the sym link.

ls -al

 

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

Migrating cPanel Accounts without homedir – The SSH Way

Step 1: Generate backups without the homedir and sync them one by one removing each backup after the transfer

Code:
for x in `\ls -A1 /var/cpanel/users/`; do /scripts/pkgacct --skiphomedir ${x} ; rsync -aP /home/cpmove-${x}.tar.gz -e ssh root@NEW-SERVER-IP:/home/ ; rm -f /home/cpmove-${x}.tar.gz ; done

Step 2: Restore all accounts on the new server

Code:
for x in `ls -A1 /home/cpmove*` ; do /scripts/restorepkg /home/${x} ; done

Step 3: Sync /home from old server to new server

Code:
 rsync -aP /home/ -e ssh root@NEW-SERVER-IP:/home/

 

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

Mozilla Firefox 4 Released

Mozilla’s official Firefox webpage hasn’t been updated yet to show the release of Firefox 4, but expect this to be done within the next 24 hours. Firefox 4 was supposed to be shipped to customers in November 2010, but several delays caused the release date to be pushed back on multiple occasions.

Firefox 4 sports many new features, such as: a refreshed user interface with tabs-on-top, improved tab organization, improved add-on organization, improved support for HTML 5 and CSS 3, and improved performance with JavaScript.

Download links for Firefox 4 are available below:

* Firefox 4 for Windows
* Firefox 4 for Mac OS X
* Firefox 4 for Linux (x86 and x64)

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

Custom php.ini on suPHP using .htaccess

Remove the lines that begin with “php_value” and “php_flag”. You will need to move these files to a file named php.ini and upload php.ini into your public_html directory. Then, add the following line into the .htaccess file in your public_html:

suPHP_ConfigPath /home/username/public_html

where “username” is your cPanel username. You will need to remove php_value and php_flag from ALL .htaccess files you may have. However, you only need to add the suPHP_ConfigPath line in the .htaccess file in your public_html directory only.

Please note that you will need to change the format of your php_value and php_flag lines into the php.ini format

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

[HowTo] Update Timezone on CentOS/RedHat

This tutorial shows you how to update timezone on your CentOS/Redhat machine. Run the command below to install system-config-date.

[root]# yum install system-config-date
[root]# setup

Go-to -> Timezone configuration -> Select your local time zone -> Click OK -> Quit.

To check your current timezone:
[root]# date
Sun Mar 15 23:50:42 MYT 2009

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]

Fix Your Streamyx Problem Today by Using TMnet Proxy

Guys, if you having packet loss problem now with streamyx, you can use these proxies.

Usable proxy list:
219.93.178.162:3128

updated: 26/04/2010

Firefox setting:

Tools ->Options->Advance->Network->Settings

proxy

Internet Explorer Setting:

Tools -> Internet Options -> Connections -> Lan Settings

ie-proxy

Notes: If you happen to get error message while surfing the net using this proxy, which means this proxy is no longer usable.

[del.icio.us] [Digg] [Reddit] [Slashdot] [StumbleUpon] [Technorati] [Windows Live] [Yahoo!]