Forum

Full Version: How to connect to a Pi /w Xbian using FTP?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi there. I'm sort of new to the Raspberry Pi, installed Xbian and now I tried to get a connected (via FTP or however) to my Pi to copy stuff from my PC to either the SD card or a connected USB stick. I know I can stream the content (and that's working just fine), but I'd like to have it on the device.
I hope you can help me out a bit. I'm just some random Windows user, so please be patient Big Grin
You mean to transfer it inside your local network right? And you have your Raspberry Pi connected to it either via ethernet cable or Wifi dongle?
If that's so, all you need to configure now is Samba sharing. Samba takes care of sharing files inside your network.
You must add the folders you wish to share with the PC to the samba config file which is located in /etc/samba/smb.conf
Terminal
xbian@Raspberry ~ $ cd /etc/samba
xbian@Raspberry /etc/samba $ sudo nano smb.conf
You should now see the config file, assure the following options are set up correctly:
PHP Code:
workgroup WORKGROUP 
interfaces 
127.0.0.0/8 eth0
bind interfaces only 
true
security 
share
guest account 
nobody 
Make sure "WORKGROUP" is the same as your windows workgroup, the interfaces option sets which type of connection it allows, if you use a ethernet cable it should be fine with that, you can also restrict it to your local ip by adding "192.168.1." where that should be your default gateway (without fixing the last numbers).
The security is set so as anyone with access to the local network can access it, if you wish I can show you how to require a user and password to access the share.
To add a folder to the share append the following to the end of the file:
PHP Code:
[Guest Share]
        
comment Guest access share
        path 
= /path/to/dir/to/share
        browseable 
yes
        read only 
yes
        guest ok 
yes 

Once done you must restart the samba server on the raspberry pi with the following command:
Terminal
sudo service samba restart
Hope it helps!
&enable SMB in XBian config (SSH or in XBMC) Wink
Yeah, that's exactly what I'm trying to do (own LAN, Pi connected to it via ethernet cable).

Now... I'm confused ^^

Where exactly do I find "/etc/samba/smb.conf"? I'm not even sure if this is supposed to be on the PC or on the Pi (I guess the Pi/Xbian).

I guess there is some kind of terminal in Xbian, but I'm not sure where/how to activate/find it.

And yepp, I'd like to set this up so that connecting to the Pi requires username/password.

So it'd be great if you could explain these two steps to me a bit more Smile
(12th May, 2013 06:20 AM)Steffko Wrote: [ -> ]Yeah, that's exactly what I'm trying to do (own LAN, Pi connected to it via ethernet cable).

Now... I'm confused ^^

Where exactly do I find "/etc/samba/smb.conf"? I'm not even sure if this is supposed to be on the PC or on the Pi (I guess the Pi/Xbian).

I guess there is some kind of terminal in Xbian, but I'm not sure where/how to activate/find it.

And yepp, I'd like to set this up so that connecting to the Pi requires username/password.

So it'd be great if you could explain these two steps to me a bit more Smile

you can connect to terminal with putty but you have to enable it (ssh) this will give you ssh-config

but its te same as the gui in xbmc in settings (but ssh gives you more low level acces )
also http://www.samba.org/samba/docs/man/manpages-3/smbpasswd.8.html
also (/etc/samba/smb.conf) is for where the servies is running so that will be the pi as you want samba on your pi
i think that you should start from helpful links on our page Wink all is there
You must type it on the Pi, on the command line, you can do it by leaving xbmc (Shutdown icon-->Exit) or you could set up an ssh connection (worth the time as it's really convenient), with it you will be able to control your raspberry pi from within your PC via command line (That's where you should write what I explained you).
To connect to your raspberry pi via ssh you must download a ssh client for windows that's called putty from here, execute it and place the Raspberry pi ip address inside host name field, you can find the ip in xbmc, system-->system information or within your local router localweb then make sure the option "SSH" is checked and click the Open button.

Once you've done it I will explain further on the security.
(12th May, 2013 06:32 AM)rikardo1979 Wrote: [ -> ]http://xbian.org/getting-started/configuring-xbian/

http://xbian.org/getting-started/install-and-connect/#ssh
all is here people...so why do something what is already done? Wink
Cool
(12th May, 2013 06:45 AM)rikardo1979 Wrote: [ -> ]
(12th May, 2013 06:32 AM)rikardo1979 Wrote: [ -> ]http://xbian.org/getting-started/configuring-xbian/

http://xbian.org/getting-started/install-and-connect/#ssh
all is here people...so why do something what is already done? Wink
Cool
True, and explained a lot better!Undecided
Next time will check if it's already explained elsewhere first Big Grin
(12th May, 2013 06:59 AM)Trinket Wrote: [ -> ]
(12th May, 2013 06:45 AM)rikardo1979 Wrote: [ -> ]
(12th May, 2013 06:32 AM)rikardo1979 Wrote: [ -> ]http://xbian.org/getting-started/configuring-xbian/

http://xbian.org/getting-started/install-and-connect/#ssh
all is here people...so why do something what is already done? Wink
Cool
True, and explained a lot better!Undecided
Next time will check if it's already explained elsewhere first Big Grin
not a big deal, but I just wanted to point out that if anyone looking for help or answer than should always start by searching an researching Wink
btw, its even in our rules Wink
Another question than. I've used the instructions on the links and this is the output of the file

Code:
[global]
        workgroup = WORKGROUP
        usershare allow guests = yes
        security=share
        follow symlinks = yes
        wide links = yes
        unix extensions = no
        lock directory = /var/cache/samba

        [xbian]
        browsable = yes
        read only = no
        guest ok = yes
        path = /home/xbian
        force user = xbian

        [devices]
        browsable = yes
        read only = no

How can I add the Pi as a network drive? I tried different thing when mapping a drive

\\192.168.*.***\xbian\home

should be it as far as I know...

(I have to exit nano with ^X, what does that mean? Feels like a stupid question.....)
did you install SAMBA package from xbian-config ?
under Sytsem>Settings or from SSH
(19th May, 2013 07:16 PM)rikardo1979 Wrote: [ -> ]did you install SAMBA package from xbian-config ?
under Sytsem>Settings or from SSH

ssh: config ==> packages
5 [Samba] [Yes]

That should be it right?
(19th May, 2013 07:07 PM)Kevf Wrote: [ -> ](I have to exit nano with ^X, what does that mean? Feels like a stupid question.....)
CTRL+x
Pages: 1 2
Reference URL's