menu hover
Hosting FAQ »

Common questions

1. I did something via control panel, but nothing changed!

2. How to fasten my server?

3. How to prevent passwords hack ftp/pop3/etc?

4. How to prevent scripts hack?

5. How to know path to the programm installed in system?

6. How to know where I am on server?

7. How to go to home directory?

8. How to go to domain directory "domain.com"?

9. Where can I read something about Unix shell-commands?

10. How to enable php error log?

11. Where can I see apache logs?

12. Where can I read about apache error-codes?

1. I did something in control panel, but nothing changed.

Changes made through panel become active in a 10 minutes.
If nothings is changed within this time, contact support, and we will solve this problem.

2. How to speed up my server?

2.1. Look for quantity of files in directories. If there are more than few thousand files, you will experience a lot of lags when you will work this directory.

2.2. Spread tasks over time using cron.

2.3. Start crons with lowered priority using

/usr/bin/nice -n 10 command

command will start with lowered priority 10 (0 - normal mode, 20 - lowest priority). Especially it will help if cron command executing for a long time.

2.4. You can use file-locks in crons to prevent start cron if older crons isn't worked out yet

For unix:
/usr/bin/lockf -kst0 /tmp/lockfile command
For linux:
/usr/bin/flock /tmp/lockfile command
3. How to prevent passwords hack ftp/pop3/... ?

Use secured protocols to connect server.
For example, you can use sftp or scp instead of ftp.
smtp, pop3, imap4 also have SSL support - enable it in your mail client.

4. How to prevent scripts hack?

You can't be completely secured, but you can minimize risk of hack your scripts (gallery generators, forums, CMS etc).

4.1. You should update your scripts often. As usual, developers update their scripts when they find any vulnerablity.

4.2. It's better to limit access to admin part of your scripts with the help of .htaccess file. There is the manual how to lock your tm3-script

4.3. You should have complex password, because hacker usually bruteforcing passwod using password-dictionaries.
Also you can use password generator: pasgen

4.4. Keep your password in secured places.

5. How to know path to the programm installed in system?

You can know path using which commandname
As example, which lynx, will show you, that lynx is located on /usr/local/bin/lynx path

# which lynx
/usr/local/bin/lynx

Paths to frequently used programms:

tar: /usr/bin/tar
perl: /usr/bin/perl
php: /usr/local/bin/php
wget: /usr/local/bin/wget
lynx: /usr/local/bin/lynx
sendmail: /usr/sbin/sendmail
ImageMagic: /usr/local/bin/convert

6. How to know where I am on server?

pwd command will show the path to your current directory

pwd
/home/username/domain.com/

7. How to go to home directory?

cd ~

8. How to go to domain directory "domain.com"?

cd ~/domain.com

9. Where can I read something about Unix shell-commands?

https://pangea.stanford.edu/computing/unix/shell/commands.php - you will find there anything you need, and more.

10. How to enable php error log?

In case of security php-logging is disabled by default. To enable them temporary, you should add this code in your php-file:

error_reporting(E_ALL);

or this line to your .htaccess file:

php_flag display_errors on

11. Where can I see apache logs?

You can see logs only for the last hour, because every 60 minutes logs are processing and will be cleaned.
Logs are located in this path:
/home/LOGS/account_name/domain.com/access/current
/home/LOGS/account_name/domain.com/error/current

where,
account_name - name of your account
domain.com - name of your domain

They're not accessible via ftp, but you can copy them using ssh to your home directory:

cp /home/LOGS/account_name/domain_name/access/current ~

or simply watch them via ssh:

less /home/LOGS/account_name/domain_name/error/current

12. Where can I read about apache error-codes?

http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html