# Remote Connections

Remote connections are easily made by typing the &URL; in the Location Toolbar; these are actually KIO Slaves. Please note that the &krusader; panel does not support all KIO Slave &eg; `http://` will not work in the panel, but will work in the viewer. Some examples:

- ``ftp://`public.ftpserver.org/folder/`

- ``fish://`username@hostname/`

- ``sftp://`username:password@sftp.foo.org/`

- ``ftp://`username@my.server.org:21/folder/`

- ``smb://`username:password@server/share`

- ``ftp://`username@proxyusername:password@proxipassword@hostname/folder`

- ``nfs://`<host>:<port><url-path>`

- ``webdav://`www.server.com/path/`

You can bookmark these &URL;s, however, please read the Bookman section regarding securely save passwords. For connecting to multiple locations, bookmark these &URL;s and open them one by one, or open them all together by using Panel profiles. To switch from one to another location, just open a Folder tabs for each.

There are three ways to start a remote connection:

- Type the &URL; in the Location Toolbar

- Select Tools New Net Connection which will pop-up a dialog that will ask for the remote site details. This dialog is handy if you are not used to type remote &URL;s in the Location Toolbar. Leaving the password and user name fields empty will log you in as anonymous. Note: we are planning to rewrite this dialog window.

- You can bookmark a folder on a remote host and return to this folder from the bookmark button on the top corner of your panel just like in a web browser.

After you log on to a remote server you can browse it just like your local hard drive with the following exceptions:

- You cannot execute files on remote servers.

- Permissions cannot always be calculated on remote servers (depends on server and access method) so you might get a ? on the permissions columns for some files.

- Disk usage information is not available for most remote filesystems.

To change the charset of the remote host use View Select Remote Charset .

You can close the current Active Remote Connection by two separate methods:

- Manually: Add the disconnect button to the Main Toolbar and click on it.

- Automatically: Change the &URL; in the Location Toolbar .

&krusader; is a file manager that supports remote connections via KIO Slaves, but if you are looking for even more advanced remote connections features, &eg; an advanced &FTP; client we recommend you to use &eg; LFTP or FileZilla.

## LAN connections via fish:/ protocol (zeroconf)

This section is contributed by Andrew Svet (z-vet), feedback about this chapter is appreciated. Thanks!

This works on a &Debian; system, so it will work on &Debian; and derivatives (&kubuntu;, &etc;), though it should work on other Linuxes as well. We assume that you have SSH installed, configured and working on every machine on LAN you want to connect to/from. There are plenty of very good tutorials about SSH on the net, &eg; at linuxhomenetworking.com or just google for it. We use the default SSH port (22) for this chapter. Remember to change it if you use different one. All modifications, editing &etc; must be done as root.

Let's start with installing all the packages we need:

    # apt-get install avahi-daemon libnss-mdns kdnssd

Everything is installed, now let's do some configuration. First, we need our services to be announced on LAN. That is why we installed avahi-daemon: it represents your machine on local network and allows other applications to publish services they provide. Avahi-daemon comes with example `ssh.service` configuration file found in `/usr/share/doc/avahi-daemon/examples`. In order to get the service to be announced on LAN we need to copy this file to `/etc/avahi/services` folder:

    # cp /usr/share/doc/avahi-daemon/examples/ssh.service /etc/avahi/services

Now we need fish:/ protocol to be announced too, so we use an ssh.service file as a template for fish.service:

    # cp /etc/avahi/services/ssh.service /etc/avahi/services/fish.service

This file is just a copy of ssh.service. Edit the `fish.service` file and replace Remote Terminal on %h with Fish to %h and _ssh._tcp with _fish._tcp.

Here is how it looks after edit:

    <?xml version="1.0" standalone='no'?><!--*-nxml-*-->
    <!DOCTYPE service-group SYSTEM "avahi-service.dtd">

    <!-- $Id: remote-connections.docbook,v 1.6 2007/05/02 18:07:28 codeknight Exp $ -->

    <!--
      This file is part of avahi.

      avahi is free software; you can redistribute it and/or modify it
      under the terms of the GNU Lesser General Public License as
      published by the Free Software Foundation; either version 2 of the
      License, or (at your option) any later version.

      avahi is distributed in the hope that it will be useful, but
      WITHOUT ANY WARRANTY; without even the implied warranty of
      MERCHANTABILITY or FITNESS FOR

    <!-- See avahi.service(5) for more information about this configuration file -->

    <service-group>

      <name replace-wildcards="yes">FISH to %h</name>

      <service>
        <type>_fish._tcp</type>
        <port>22</port>
      </service>

    </service-group>

Save the modified file.

Now we need to create a new file `_fish._tcp`, open a text editor and add the next lines:

    Name=FISH Protocol (ssh)
    Type=_fish._tcp
    UserEntry=u
    PathEntry=path
    PasswordEntry=p

And save the file `/usr/share/apps/zeroconf/_fish._tcp`

Do the same on each machine on your LAN, then restart avahi-daemon:

    # /etc/init.d/ avahi-daemon restart

Then open &krusader; and type in location-toolbar-lnk: `zeroconf:/` to open the zeroconf connection. Enter the Fish Protocol folder. Inside you will find the links to each machine that announced `fish:/` on your LAN, the location-toolbar-lnk: will point to `zeroconf:/_fish._tcp` Double clicking on any of these machines, them will bring up the password prompt, asking you for your ssh key passphrase (if password was set). Enter your passphrase. Congratulations: you connected to remote machine using &krusader;!