Long hiatus…

I apologize to all of my readers, as I’ve realized that I slacked off quite a bit on keeping this blog updated…well that’s going to change. As you can see the ugly dark design is gone, and has been replaced with a cleaner design. I’m also in the process of updating the ‘About’ and ‘cPanel Introduction’ pages, both of which need work especially the cPanel page, since it’s a complete mess and a pain to navigate. Be sure to check back for these changes in the next few days!

Backup/Restore a cPanel Account

Previous Post: WHM Scripts

Now we’re going to start looking into some of those SSH commands.  Today we’ll be going over the commands pkgacct and restorepkg.

Backing up and restoring cPanel account’s is, in my opinion, faster by using the command line as you don’t have to wait for a sometimes sluggish web interface to load.

Let’s get started then, shall we? Continue reading ‘Backup/Restore a cPanel Account’

WHM Scripts

Did you know that if you have cPanel/WHM on your server, you also have a bunch of serverside commands that you can use?  These are good for advanced users, or the people who prefer to manage their servers in a hurry via the command line rather than waiting for a web interface to load.

Nearly everything that you can do in the WHM backend can be performed via command line.  These scripts are located in your server’s /scripts/ directory.  Only use scripts that have been verified by cPanel, or that you know yourself are safe as an unsafe script may damage your server.

Long list of scripts after the break… Continue reading ‘WHM Scripts’

Installing RKHunter

Be honest, how much have you considered server security in the past?  In this day and age, it’s not something that should be taken lightly.  Today I’ll be teaching you how to install RKHunter.  RKHunter (ie:  Rootkit Hunter) is a nifty little script that runs via cron daily that checks your server for the most obvious rootkits that might have been placed there by somebody with some kind of malicious intent.

Continue reading ‘Installing RKHunter’

Session.save_path error

So…I came across this error on a clients site which he was receiving when trying to install a 3rd party script.

The session.save_path setting in your php configuration file (php.ini) is not set or is set to a folder which did not exist. You might need to set the save_path setting in php.ini or verify that the folder sets in save_path exist.

It’s a pretty simple fix in the servers php.ini. Continue reading ‘Session.save_path error’

Install fantastico on cPanel

A fantastico installation is pretty straight forward. First thing you need to do is obtain a Fantastico license from Netenburg.

One of the most common issues when installing fantastico is a buggy wget install on the server, so a working wget version will need to be installed. Another common issue is cPanels internal php may break, but we will discuss the fix to that later on. Continue reading ‘Install fantastico on cPanel’

Exim Error: Ratelimit database not available

2009-07-20 21:58:07 Failed to get write lock for /var/spool/exim/db/ratelimit.lockfile: timed out
2008-07-20 21:58:07 H=[xx.xx.xx.xx] temporarily rejected connection in “connect” ACL: ratelimit database not available

To fix such an error , the exim cache database on the server side needs to be clear off to stop this message. Continue reading ‘Exim Error: Ratelimit database not available’

Creating an extracting tar files

The most common compressed archive file format in Linux is the tar.gz format. Tar file is an archive file format. Tar.gz is a compressed tar file.

How to create a compressed tar.gz file from a folder or file in Linux?

In order to create a compressed tar.gz archive from a folder/file we need to run the following tar command:

tar -czf new-tar-file-name.tar.gz file-or-folder-to-archive

Here is the command explanation:

  • tar – the tar command.
  • c – create new archive.
  • z – compress the archive using gzip.
  • f – use archive file.
  • new-tar-file-name.tar.gz – the name of the tar.gz to create.
  • file-or-folder-to-archive – the name of the folder we want to archive.

Continue reading ‘Creating an extracting tar files’

cPanel Icon Missing From WHM List Accounts

I came across an issue for the first time where the cPanel icon was missing in the list accounts section. After digging around WHM, I found where the function was disabled.

  • Log into WHM
  • Select “Tweak Settings”
  • Uncheck the box next to “Disable login with root or reseller password into the users’ cPanel interface. Also disable switch account dropdown in themes with switch account feature”
  • Click save

After hitting save, you can go back to the list account section and the cPanel icon will be back.

pty, ptyp, and tty errors

So I came across this error for the first time today when trying to SSH directly into a clients VPS.

login as: root
root@server’s password:
Server refused to allocate pty
stdin: is not a tty

After a quick google search I came across the fix.

[root@node /]# vzlist -a
VEID      NPROC STATUS  IP_ADDR         HOSTNAME
1337         78 running 69.10.59.80     grumpy.thelinuxnoob.com
[root@node /]# vzctl exec 1337 /sbin/MAKEDEV ptyp
[root@node /]# vzctl exec 1337 /sbin/MAKEDEV tty
[root@node /]# vzctl exec 1337 /sbin/MAKEDEV pty

The issue should now be resolved and you can SSH into the VPS.