LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 02-06-2003, 12:04 PM   #1
cmfarley19
Member
 
Registered: Nov 2002
Location: Central VA
Distribution: Ubuntu/Debian
Posts: 228

Rep: Reputation: 32
Samba Mount Problem


I attempted to do a Samba mount to access a directory on my windows box from my linux box. So I did the mount command. The result follows:
wombat:/home/cfarley# mount -t smbfs -o username=uname //host/dir /home/cfarley/winshare
ERROR: smbfs filesystem not supported by the kernel
Please refer to the smbmnt(8) manual page
smbmnt failed: 255

wombat:/home/cfarley#

So I attempted an apt-get (I have debian)

wombat:/home/cfarley# apt-get install smbfs
Reading Package Lists... Done
Building Dependency Tree... Done
Sorry, smbfs is already the newest version.
0 packages upgraded, 0 newly installed, 0 to remove and 65 not upgraded.


Any thoughts?
 
Old 02-06-2003, 01:59 PM   #2
RonS
LQ Newbie
 
Registered: Jan 2003
Location: WI USA
Posts: 23

Rep: Reputation: 15
How about:
smbmount //host/dir /home/cfarley/winshare
 
Old 02-07-2003, 04:48 AM   #3
cmfarley19
Member
 
Registered: Nov 2002
Location: Central VA
Distribution: Ubuntu/Debian
Posts: 228

Original Poster
Rep: Reputation: 32
Nope... same thing...
wombat:/home/cfarley# smbmount //host/dir /home/cfarley/winshare -o username=uname
Password:
ERROR: smbfs filesystem not supported by the kernel
Please refer to the smbmnt(8) manual page
smbmnt failed: 255

wombat:/home/cfarley#
 
Old 02-07-2003, 10:40 AM   #4
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
Does smbclient work?
(smbclient '\\host\dir' -U uname -W windowdomain
(you may not need the -W option))

Your windowbox may not be willing to "share" the folder.
In that case, you'd need to set up the share.
 
Old 02-07-2003, 12:17 PM   #5
RonS
LQ Newbie
 
Registered: Jan 2003
Location: WI USA
Posts: 23

Rep: Reputation: 15
What does 'smbclient -L \\windowshost ' tell you?
If that fails how about 'smbclient -L \\linuxhost '?

Of course, substitute your machine names for linuxhost and windowshost.
 
Old 02-07-2003, 12:42 PM   #6
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
I suggested smbclient just to see if the windowbox share is set up so that the linux box is allowed to use it. Unless you want to cross-mount your drives (which may be a bad idea), the linux box does not have to be running smb server. smbmount works without smb server on. On the other hand, if smb server is working, why not use the drive on the linux box, as it can be accessed from the windowbox.
 
Old 02-07-2003, 12:59 PM   #7
cmfarley19
Member
 
Registered: Nov 2002
Location: Central VA
Distribution: Ubuntu/Debian
Posts: 228

Original Poster
Rep: Reputation: 32
Shin and Ron
smbclient worked to connect.
Here is what I am attempting to do...
I have a home network. I run Windows on the machine I do most of my "work" on. (Yeah, I know... I'm working on it. The wife can't deal, anyway) I run Debian GNU/Linux running a LAMP setup for my web server. I want to back up my critical web stuff and the only place to back up to is my windows machine. Not a rock-solid set-up but better than nothing. I want to mount a share to my linux box, tarball and gunzip my web stuff and copy it to my windows box. I want to do this via a cron script.

Thoughts?
 
Old 02-07-2003, 01:31 PM   #8
RonS
LQ Newbie
 
Registered: Jan 2003
Location: WI USA
Posts: 23

Rep: Reputation: 15
If you want to mount the windows share in Linux automatically on boot, try adding a line to /etc/fstab like this:
//servername/share /mountpoint smbfs auto,username=user,password=user_password
 
Old 02-07-2003, 01:41 PM   #9
cmfarley19
Member
 
Registered: Nov 2002
Location: Central VA
Distribution: Ubuntu/Debian
Posts: 228

Original Poster
Rep: Reputation: 32
Ron,
Agreed, but see my original post.
SMBFS not supported by kernel.
 
Old 02-07-2003, 04:58 PM   #10
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
I can't help you with the issue of SMBSF not being supported by the kernel. But if what you want to do is to store a tarball on PC, may be you can try the following (at least as a short term solution till you can figure out the SMBFS issue)

1. Get an ftp daemon for Windowbox. I haven't checked if there is one available for free. We have something like that which came with Autoweb client. (I can't give this to you, since I don't want barracudas on my tail).

2. Write an ftp_script which contains lines like
cd C:\storagedirectory
bin
mput backup*.tar.gz

3. put the script in the directory where you create the tarball. Assume you have backup_2003Feb07.tar.gz file in the directory also. Issue a command

ftp i host < ftp_script

this is supposed to ftp backup_2003Feb07.tar.gz. I have done this between *nix boxes. With windowbox, you may need some tinkering. If ftp (server) requires login ID and password, you can put the pair into .nerc file on the home directory (of the user that will run ftp session) The format of .netrc file is

machine machinenameorIP login useID password passwd

for example,

machine host login stakeshita password Pa55vvorcl
machine 198.162.0.13 login JoeUser password IneedFtp

4. You can incorporate this in your script that you are going to cron.

The presence of .netrc file is a security risk (since it is a listing of userID and unencrypted password). Don't do this unless your linux box is well protected. Or may be you can get you windowbox to accept annonymous ftp login.
 
Old 02-10-2003, 12:42 PM   #11
Shin Takeshita
LQ Newbie
 
Registered: Dec 2002
Location: Novi, MI
Distribution: Red Hat
Posts: 25

Rep: Reputation: 15
I just did a similar "experiment" sith smbclient.

Create a file (call it smbupload) that contains something like

cd yourarchivedirectory
put yourarchive.tar.gz
exit

(You may have to put "bin" somewhere, but I'll let you experiment)

Command on bash (I presume ksh would work, too)

smbclient '\\yourWindowox\sharedDirectory' yourpassword -U yourwindowID -W yourDomain < smbupload

will send the archive file. This may be less messy, since you
don't have to play with .netrc. (You still have to store
the password on your shell script, alas)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
samba mount when not owner of mount point cotton213 Linux - General 1 08-04-2005 06:21 AM
Permissions on a samba mount of a samba mount rimcrazy Linux - Networking 0 04-15-2005 07:57 AM
samba mount problem clockworks Linux - Software 0 04-21-2004 12:47 PM
Samba: Authenticate Linux-Clients in Samba Domain & Mount mule Linux - Software 0 12-10-2003 01:21 AM
samba mount problem jinujose Linux - Networking 2 10-09-2003 10:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration