2011-02-20, 01:01
chris2922 Wrote:Yes muDD you're right, looks like the process of installing XBMCbuntu doesnt include the Samba Client or File System. Or at least not with the guide i used:
http://wiki.xbmc.org/?title=XBMCbuntu
Without Samba we can't browse our smb shares.
I've just installed XBMCbuntu from scratch and taken slow/small steps towards fixing this in the hope of working out exactly what we all need to do. Works for me now, and as someone said in an earlier post - it actually scans and scrapes a hell of a lot faster if you 'mount' the shares. About 1-2 seconds per film as it just did my collection.
Following an install of XBMCbuntu, when you get the Error 2 Share Not Available error do this to fix:
*note: im using a remote linux command line program called Putty.exe to log in to my XBMC box. (google it) This way i can run command line stuff on a windows machine with the internet to hand should i get in a mess. Its also handy for copy/pasting longer commands into Putty.*
If you installed Ubuntu Server 9.10 and then XBMC you'll find the 'xbmc' user doesnt have root privaliges. If this is the case, either add the 'xbmc' user to the sudoers list, or log in as your main user - a member of 'sudoers'.
From the command line Install 'smbfs' & 'smbclient' (Samba File System & Samba client):
sudo apt-get install smbfs smbclient
This installs about 50mb of stuff and then returns to the prompt.
My NAS box has a static ipaddress so for me i need to enter the following command to check for shares now i have samba installed:
smbclient -L 192.168.1.xxx -U%
You'll have to change the ip to match yours, or use the 'name' of the server instead.
Now to get that extra bit of scraping speed we will 'mount' the shares locally rather than scan for them each time.
To mount you need to create a local folder to serve as a mount point for each share. I have 2 shares on my NAS box, one called 'Film' and one called 'TV'.
So i create 2 folders in my 'xbmc' users /home folder.
Im currently logged in as my /root enabled user (so i could install samba earlier) so i changed login here (closed Putty.exe and reopened it).
Now im logged in as 'xbmc' i created 2 folders:
cd ~
mkdir film
cd ~
mkdir tv
To mount the 2 shares on my NAS to these 2 local folder each time i boot up i need to edit the 'fstab' file. This requires /root privs again, so if you have to, change users again by loggin out and back in. Then as your root powered user:
cd ~
cd /etc
sudo nano fstab
This file is a bit confusing to be honest. Just go to the bottom of the file and enter as many new lines as you need new mounts. I have 2 to add.
My NAS has a username/password system in place. I have had to add the credentials to the end of the mounting commands - change them to match yours or remove them if you have none.
Mine look like this (2 lines only for me, so theyre different colours in case your screen is squashing them):
//192.168.1.xxx/share/TV /home/xbmc/tv smbfs auto,username=xbmc,password=xbmc
//192.168.1.xxx/share/Film /home/xbmc/film smbfs auto,username=xbmc,password=xbmc
Now 'Ctrl-X' to exit, press 'Y' to save, then 'Return' to overwrite your existing 'fstab'.
Now reboot, and when back in XBMC, instead of trying to 'browse' for a source in 'smb', go into 'home' and use your mount points.
This has just worked for me fine. If you cant be arsed with the whole mounting thing, just going back to the top of this post and entering:
sudo apt-get install smbfs smbclient
as root at command line will fix the Error 2 Share Not Found error. Im just so impressed with the added speed this method got for me i thought id share.
Oh dear, that was a terrible pun....
I'm trying to do the above but for some reason it doesn't seem to mount the drives on boot. The only thing different is the share doesn't require a username and password so i deleted the username and password parts. If i ssh into the machine and send the command sudo mount -a it asks for a password (which i leave blank) and all the shares are mounted correctly so i believe my entries in fstab are valid. Have I done something wrong?