Kodi Community Forum

Full Version: How do I format an additional HD? ...and how to copy files from Windows?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
EDIT: I've figured it out but I still have one question.

I'm storing my media files in /home/xbmc/media (which has 777 permissions).

Inside smb.conf I have the following:

Code:
[hd1]
  comment = Hard Drive 1
  path = /home/xbmc/media
  guest ok = yes
  read only = no
  writeable = yes
  writable = yes ; (which is correct?  writeable or writable?)
  guest account = xbmc

However, when I try to connect to \\htpc\hd1 it gives me access denied.

What am I doing wrong?
You should post your full smb.conf file and also check the logfiles in /var/log/samba.

Temar
Here you go:

smbd.conf: http://pastebin.com/m4d789264
log.smbd: http://pastebin.com/m271e9066
log.nmbd: http://pastebin.com/m35a0fc96

I can connect to [hd2] and [hd3] just fine. It's [hd1] that won't let me connect. (because it's inside \home\xbmc I guess?) As far as I can tell, I'm logging in as a guest from Vista to samba.
This is what i am using, you might want to try if it works for you too.
Code:
[hd1]
        comment = Hard Drive 1
        path = /home/xbmc/media
        guest ok = Yes
        read only = No
        force group = xbmc
        force user = xbmc
Thanks. I tried adding force user and force group to my config but it didn't work. Sad
Myself I've had no end of problems with Windows NT 5.1 and later trying to connect to Samba shares...I'm sure there's ways around it, but the fact that all my non-Windows computers connect fine but any Windows machines fail out claiming they need login information makes me think it's actually Windows that's at fault (I had nearly identical problems back in the day between Win98 and WinXP).

I could make guesses (like for example it's complaining about CUPS, maybe Vista is getting told it can't talk to the printer and thus is assuming it's not allowed to be there at all?), but admittedly I don't really know. What I do know is what I showed my roommates, who both run Windows, in the form of two alternate ways of getting at the data.

The easiest thing to do is just use SFTP. Get something like WinSCP and just use it instead, all you have to have is your XBMC machine running an SSH server and then you can just log in as xbmc, no fiddling with other permissions or services since you're directly logging in as that very user, in a very linux-y way.

The other thing would be to run an HTTP server on the XBMC computer and have it sharing the files. I do that myself as well (for my less tech-savvy roommate who finds even WinSCP a bit bewildering). In my case I went simple, just installed apache, then added symlinks in /var/www/ going to where I had files. For example, if my computer was set up like yours I'd probably go:

Code:
sudo ln -s /home/xbmc/media/ /var/www/media
where the first path there is where the real folder is, and /var/www/games is the link I'm creating. Now if my roommate goes to (for the sake of argument) http://xbmc, he sees a folder named "media", and going into it he can get at whatever's in there. (You might have to delete or move the default index.html file in /var/www/, I forget now how it's set up at first, at very least going directly to http://xbmc/media/ should work).


....hopefully some genius can figure out why samba isn't working for you, but basically failing that I figure there's lots of other ways of sharing files, these are just two of them Smile
Thanks for the reply.

I ended up making a symbolic link from /mnt/hd1 to /home/xbmc/media and then specifying /mnt/hd1 inside smb.conf and it worked.

I'm not sure why I had to use this roundabout method but it works so whatever. Smile

Thanks for the help!