Accessing Your Data

Aside from the control panel, there are two other key ways to access your account and data. The first is by remotely working with each machine your account has access to with SSH. The second is with FTP.

Connecting with SSH

You can connect to a particular machine with SSH. SSH is short for Secure Shell and allows you to work with a remote computer with the command line securely and robustly.

To connect with SSH you will use the following information:

  • Host: username.webfactional.com (if you account is only associated with one machine) or webXX.webfaction.com.
  • Username: your WebFaction account name.
  • Password: your WebFaction SSH password.

On Mac OS X and Linux systems, you can connect using the command line program ssh. At the command line, simply enter ssh username@username.webfactional.com and press Enter.

On Windows, you will need an SSH client, like PuTTY. To connect to your account with PuTTY:

  1. Start the PuTTY application.
  2. In the Host Name (or IP address) field, enter username@username.webfactional.com where username is your WebFaction username.
  3. Click the Open button.
  4. The first time you connect, a PuTTY Security Alert appears. Click the Yes button to add the server to the list of known hosts.
  5. In the main PuTTY window, a password prompt appears. Enter your WebFaction account password and press Enter.

You’re now connected with SSH using PuTTY.

Using SSH Keys

You can use a password-less, key-based SSH authentication system with your WebFaction account.

Linux and Mac OS X

To create and deploy a key with Linux or Mac OS X:

  1. Create a key on your local computer.
    1. Open a terminal session.
    2. Create ~/.ssh, if it does not already exist. Enter mkdir -p $HOME/.ssh.
    3. Switch to the ~/.ssh directory. Enter cd ~/.ssh and press Enter.
    4. Generate your keys. Enter ssh-keygen -t dsa.
    5. A series of prompts appear. Press Enter for each to accept the defaults.
  2. Deploy the key to your WebFaction account.
    1. Copy the key to your WebFaction account. Enter scp ~/.ssh/id_dsa.pub username@username.webfactional.com:temp_id_dsa_key.pub and press Enter. When prompted, enter your password.
    2. Open an SSH session to your account. Enter ssh username@username.webfactional.com and press Enter. When prompted, enter your password.
    3. Create ~/.ssh, if it does not already exist. Enter mkdir -p $HOME/.ssh.
    4. Add your key to the authorized_keys file. Enter cat ~/temp_id_dsa_key.pub >> ~/.ssh/authorized_keys and press Enter.
    5. Remove the temporary key file. Enter rm temp_id_dsa_key.pub and press Enter.
    6. Secure the SSH keys. Enter chmod 600 ~/.ssh/authorized_keys and press Enter.
    7. Secure the SSH directory. Enter chmod 700 ~/.ssh and press Enter
    8. Secure your home directory. Enter chmod go-w $HOME and press Enter.
    9. Close the SSH session.
  3. Verify that your key works properly. Enter ssh username@username.webfactional.com and press Enter. The session should begin without a prompt for a password.

PuTTY

To create and deploy a key with PuTTY:

  1. Create a key on your local computer.
    1. Download puttygen.exe.
    2. Run puttygen.exe. The PuTTY Key Generator window appears.
    3. Click to select SSH-2 DSA.
    4. Click the Generate button.
    5. Generate randomness by moving your cursor around until the key is finished.
    6. Click the Save private key button.
    7. Click the Yes button.
    8. Save the file to c:\ssh\id_dsa.ppk.
    9. Click the Save public key button.
    10. Save the file to c:\ssh\id_dsa.pub.
    11. In the Public key for pasting into OpenSSH authorized_keys file field, select and copy the key text.
  2. Deploy the key to your WebFaction account.
    1. With PuTTY, open an SSH session to your account.
    2. Create the ~/.ssh directoryirectory. Enter mkdir -p ~/.ssh and press Enter.
    3. Open ~/.ssh/authorized_keys in a text editor. For example, enter nano -w ~/.ssh/authorized_keys and press Enter.
    4. Paste the key text such that the key is alone on a single line.
    5. Save and close the file.
    6. Secure the SSH keys. Enter chmod 600 ~/.ssh/authorized_keys and press Enter.
    7. Secure the SSH directory. Enter chmod 700 ~/.ssh and press Enter
    8. Secure your home directory. Enter chmod go-w $HOME and press Enter.
    9. Close PuTTY.
  3. Configure PuTTY to use key authentication.
    1. In the Host Name (or IP address) field, enter username@username.webfactional.com.
    2. In the Category menu, click to expand SSH.
    3. In the Category menu, click to select Auth.
    4. In the Private key file for authentication, enter c:\ssh\id_dsa.ppk.
    5. In the Category menu, click to select Session.
    6. In the Saved Sessions field, enter a name for the connection.
    7. Click the Save button. The connection name appears in the list.
  4. Verify that your key works properly. Double-click the connection name in the list. The session should begin without a prompt for a password.

Troubleshooting SSH Connections

If you’re having trouble connecting with SSH, try these troubleshooting strategies:

  • If you encounter a Connection timed out or Connection refused error, check your internet connection and try again. If your connection is working properly, please open a support ticket. As a security precaution, your IP address may have been temporarily banned after several consecutive failed connection attempts.

  • If you encounter a Permission denied error, make sure your SSH server details and credentials are correct. Confirm that you’re connecting to the correct host name. Likewise, make sure you’re using the correct username and password.

    If you’re key-based authentication, verify that your private key is available on your local computer and that your public key is deployed to the remote WebFaction server.

Connecting with FTP

You can review, change, and create files in your home directory with the FTP protocol. WebFaction supports FTP and SFTP. SFTP is much more secure than FTP; SFTP is highly recommended.

To connect with SFTP you will use the following information:

  • Server: username.webfactional.com
  • Connection type: SFTP
  • Port: 22
  • Username: your WebFaction account name.
  • Password: your WebFaction SSH password.

To connect with FTP, substitute the connection type with FTP and the port number with 21.

You can use this configuration information in your FTP client. If you do not have an FTP client already, there are many free clients available, such as FileZilla (cross-platform), Cyberduck (Mac OS X), and FireFTP (a Firefox extension).

Changing Your FTP or SSH Password

If you have forgotten your SSH or FTP password, you can change your password with the control panel.

  1. Log in to the WebFaction control panel.
  2. Click Account ‣ Change SSH/FTP password. The Change SSH/FTP password page appears.
  3. In the New SSH/FTP password field, enter your new password.
  4. In the Confirm password field, reenter your new password.
  5. Click Change. Your new password is now set.

Additional Users

If you’re working with a team or need to grant limited access to someone else, you can create additional users. Extra users have their own (unique per machine) username, password, and home directory.

See also

To learn how to grant additional users access to your applications, see Granting Access to Specific Users.

Creating Additional Users

You can create an extra user from the control panel. To create a user:

  1. Log in to the WebFaction control panel.
  2. Click Account ‣ SSH/sftp users. The Users list appears.
  3. Click the Add new (add new) button. The Add page appears.
  4. Click to select a server on which to create the new user in the Machine menu.
  5. Enter a username unique to that server in the Username field.
  6. Click to select a shell type from the Shell menu. Select /bin/bash for the typical Bash shell; select No shell (sftp only) if the additional user should not have shell access.
  7. If needed, click to select (Ctrl or Command click to select more than one group) groups to add the user to.
  8. Click the Create button. The View page appears with a confirmation message and default password.

Removing Additional Users

You can delete an extra user from the control panel. To delete a user:

  1. Log in to the WebFaction control panel.
  2. Click Account ‣ SSH/sftp users. The Users list appears.
  3. Click the Delete (delete) in the row of the user to be removed. A prompt, Warning: Deleting this user will delete its home directory as well. Are you sure you want to delete this user? appears.
  4. Click OK to continue. The Users list appears with a confirmation message.

Backups

WebFaction conducts a daily backup of all home directories, email accounts, databases, and cron jobs. We retain these backups for ten days. While we take great care to protect each server from data loss, we do not guarantee the availability of our backups and strongly urge you to make your own backups of your important data.

If you would like to have something restored from our backups, please open a ticket and let the WebFaction support team know what data from what date you would like restored.