Uploading to your site

This section describes uploading via FTP, DirectAdmin file manager and SSH. You can download using any of these methods.

Directory structure

These directories exist in the root of your account:

  • /backups
  • /domains
  • /imap
  • /Maildir
  • /public_html

/backups

The /backups directory contains all backups created using the control panel. You won’t have a /backups directory until you create a backup in the control panel.

/domains

The /domains directory contains files related to your hosting account. Each domain hosted in your account has its own directory (/domains/example.com). This directory contains:

  • /logs monthly logs are stored here – the directory is created one month after you create your account
  • /private_html files for your encrypted website when it uses an ssl certificate
  • /public_html files for your website
  • /public_ftp files for your FTP site
  • /stats files created by Webalizer for statistics – do not change or delete this directory

/imap

Each IMAP folder (usually for incoming messages) has subfolders new and cur. The new subfolder contains all new messages that have not yet been viewed by any email client (whether offline or online). Normally, you view them through a mail client (POP3 or IMAP), otherwise, if you view them in SSH, FTP or the file manager, they will not be marked as read.

/Maildir

/Maildir is a system storage for mailboxes. It has nothing to do with virtual mailboxes. In most cases, the storage box contains errors and notifications from the system.

/public_html

The /public_html directory at the root of your account is a link to /domains/example.com/public_html. If your account hosts multiple domains, this link will redirect you to the public_html directory of the last domain created in your account.

Home (index.html) file

The default file for any web directory is index.html. This means that when visitors access http://www.example.com, the server actually sends them to http://www.example.com/index.html. This works for any public directory on your system, including subdomains.

When loading the main website file for each directory, don’t forget to name it index.html. Experienced users can use PHP files, shtml files, etc. If your website is not based on html, make sure that your main files are renamed to index.extension (e.g. index.php, index.shtml).

Uploading from FTP

Step 1: Download the FTP client.

Uploading to the server via FTP requires special software. Most computer systems do not come with FTP clients, so you will have to download them from the Internet. We highly recommend FileZilla.

Step 2: Connect to the server.

Uploading to your site

If you use FileZilla, the information should look like this:

Uploading to your site

All FTP clients need the following information:

  • User name (this is your user name in the control panel).
  • Password (This is your control panel password.)
  • Address (Host) (This is the server address. Use ftp.example.com)
  • Port (Use default port 21)

Step 3: Open the public_html directory and upload your files.

Once connected, you can see your folders in the right pane. You can click on the desired folder to see its contents. If you have multiple domains hosted in your account, you must first go into the /domains directory, then the domain you want to edit, then the public_html directory.

To download, select the files/folders on your computer and drag them to the appropriate directory on the remote server. Each FTP client works differently, so please refer to its help file for complete instructions.

Downloading with the DirectAdmin file manager

Downloading with the DirectAdmin File Manager is an easy way to transfer files between your computer and the server without any additional programs.

  • Uploading to your siteUploading to your site 1. Log in to the Control Panel and click the System and Files icon.
  • 2. Select the File Manager menu.
  • 3. Navigate to the directory where you want to download the files.
  • 4. Tap the Upload File button at the top of the screen.Uploading to your site
    Uploading to your site
  • 5. After that, simply drag the desired items from your computer to DirectAdmin and click “Load”.
  • 6. Note. Make sure that the path to the above is correct. (the path starts with a slash – / in your home directory).

Uploading files using the DirectAdmin File Manager is really easy and useful. You can also change file permissions or even edit files from the direct admin control panel. You can find all of these features with a detailed usage guide here.

Downloading via SSH

With SSH you can log in to the server and download files directly from other servers.

  • Note: Some hosting companies may disable the SSH feature for security reasons.
  • Note: SSH should not be used by those who are not familiar with the Unix environment.

Connect to the server with the terminal using OpenSSH

Just open a terminal (Linux/MacOS only) and type your username and server name. Example:

ssh user@example.com

You will be prompted for a password. Do that and press Enter

  • Note: you won’t see the password characters displayed, it’s okay, just type it in and press enter.
  • Note: The default port of the ssh server is 22. If your server has a different port, you must specify it when connecting via ssh terminal. Example:
ssh -p 2222 user@example.com

Where -p is the port and 2222 is the port number of your server.

Connect to the server using PuTTy

Download PuTTy from here.

Uploading to your site

Enter your hostname and port (the default is 22)

Click Open. You will continue to the terminal and enter your user name and password. Once connected, the steps below are the same as for OpenSSH and PuTTy.

Navigate to the directory where you want your files to be uploaded

Once connected, you will appear in your home directory. However, you may want to access your public_html directory, you can do this with the cd command. Example:

cd /home/user/domains/example.com/public_html/

Where user is your username and example.com is your domain name. You can also access public_html simply by typing

cd domains/example.com/public_html/

Since ssh registers you in your home directory by entering the full path, you will always have access to the folder you want.

File Downloads.

You can now download files by using the wget command. Just enter:

wget https://www.yourstoragedomain.com/filename.png

You can also download from an FTP server using wget. To do this, simply enter:

wget ftp://username:password@ftp.yourstoragedomain.com/filename.png

wget has many more options to learn all about them, you can get more information here.

Using rsync to synchronize files

Warning : using rsync can cause the file to be deleted, so make sure you do before using rsync.

rsync is a powerful tool for synchronizing files between servers or simply downloading one from another. Example usage:

rsync -avt olduser@olddomain.com:/home/olduser/domains/olddomain.com/public_html/logo.png user@newdomain.com:/home/user/domains/newdomain.com/public_html/

Where:

  • olduser is the user you want to download the logo.png file from
  • olddomain.com is the domain from which you want to download the logo.png file
  • logo.png is the file from olddomain.com that you want to transfer to newdomain.com
  • user is the user from the new server from which you want your file to be downloaded.
  • newdomain.com is the domain where you want your file to be downloaded.
  • public_html is the folder where the logo.png file will be loaded. don’t forget to put / at the end.

rsync is a very powerful tool with many features, if you want to know more about it, you can read about them here.

 Control Panel - Directadmin
Total 0 Votes:
0

Tell us how can we improve this post?

+ = Verify Human or Spambot ?