You are Here:
Linux Lite 6.6 FINAL Released - Support for 22 Languages Added - See Release Announcement Section



Windows file share - accessing network file storage 'outside' file manager

Author (Read 8620 times)

0 Members and 1 Guest are viewing this topic.

 

Wirezfree

  • PayPal Supporter
  • Platinum Level Poster
  • *****
  • 1484
    Posts
  • Reputation: 405
  • Linux Lite "Advocate"
    • View Profile

  • CPU: i7-4790S

  • MEMORY: 16Gb

  • VIDEO CARD: Intel HD4600 (Integrated)
Hi Valtam,

I spoke to soon.. In my excitement I only browsed an opened files, I tried to write... failed
The permissions on the directory read only and owned by Root, and unable to change.

I tried the obvious to "chown" it, that fails with:
Code: [Select]
dave@asus-mini-2:~$ sudo chown -R dave: /wdshared
[sudo] password for dave:
chown: cannot access ‘/wdshared’: No such file or directory

In the dmesg log file I found this:
Code: [Select]
[    6.935001] FS-Cache: Netfs 'cifs' registered for caching
[    6.935367] Key type cifs.spnego registered
[    6.935376] Key type cifs.idmap registered
[    6.938501] CIFS VFS: Error connecting to socket. Aborting operation.
[    6.938540] CIFS VFS: cifs_mount failed w/return code = -101
[    6.939277] CIFS VFS: Error connecting to socket. Aborting operation.
[    6.939328] CIFS VFS: cifs_mount failed w/return code = -101
[    7.048379] CIFS VFS: Error connecting to socket. Aborting operation.
[    7.050122] CIFS VFS: Error connecting to socket. Aborting operation.
[    7.050455] CIFS VFS: cifs_mount failed w/return code = -101
[    7.050800] CIFS VFS: cifs_mount failed w/return code = -101

Additional Note:
If I navigate through Thunar, Browse network to the same location everything works fine.
So using the fstab method seems to turn the folder to root user, and then it's RO for me.

NEW THREAD:
https://www.linuxliteos.com/forums/index.php?topic=589.0

David
« Last Edit: July 12, 2014, 05:16:26 PM by Wirezfree »
Upgrades WIP 2.6 to 2.8 - (6 X 2.6 to 2.8 completed on: 20/02/16 All O.K )
Linux Lite 3.0 Humming on a ASRock N3070 Mobo ~ btrfs RAID 10 Install on 4 Disks :)

Computers Early days:
ZX Spectrum(1982) , HP-150 MS-DOS(1983) , Amstrad CPC464(1984) ,  BBC Micro B+64(1985) , My First PC HP-Vectra(1987)
 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Good stuff :)
 

 

Wirezfree

  • PayPal Supporter
  • Platinum Level Poster
  • *****
  • 1484
    Posts
  • Reputation: 405
  • Linux Lite "Advocate"
    • View Profile

  • CPU: i7-4790S

  • MEMORY: 16Gb

  • VIDEO CARD: Intel HD4600 (Integrated)
Sorry for jumping on the thread..??
Can you do this to a NAS Drive/Share..??

Should be able to, if it starts to get messy, start another thread :)

Hi Valtam,

Works perfectly, just used user name/password for my NAS in the .creds
Now have folder/link straight to my shared NAS folder
Like this:
Code: [Select]
# WD NAS1 Shared
//wd-nas1/shared /home/dave/wdhared cifs users,credentials=/home/dave/.creds,workgroup=homenet,ip=10.10.10.10 0 0

Many Thanks... Dave
Upgrades WIP 2.6 to 2.8 - (6 X 2.6 to 2.8 completed on: 20/02/16 All O.K )
Linux Lite 3.0 Humming on a ASRock N3070 Mobo ~ btrfs RAID 10 Install on 4 Disks :)

Computers Early days:
ZX Spectrum(1982) , HP-150 MS-DOS(1983) , Amstrad CPC464(1984) ,  BBC Micro B+64(1985) , My First PC HP-Vectra(1987)
 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Sorry for jumping on the thread..??
Can you do this to a NAS Drive/Share..??

Should be able to, if it starts to get messy, start another thread :)
 

 

Wirezfree

  • PayPal Supporter
  • Platinum Level Poster
  • *****
  • 1484
    Posts
  • Reputation: 405
  • Linux Lite "Advocate"
    • View Profile

  • CPU: i7-4790S

  • MEMORY: 16Gb

  • VIDEO CARD: Intel HD4600 (Integrated)
Hi Valtam,

Sorry for jumping on the tread..??
Can you do this to a NAS Drive/Share..??

Rather than a shorcut to a NAS Share,
make the NAS share look like a folder in Thunar.?

I can create another thread if required.

David
Upgrades WIP 2.6 to 2.8 - (6 X 2.6 to 2.8 completed on: 20/02/16 All O.K )
Linux Lite 3.0 Humming on a ASRock N3070 Mobo ~ btrfs RAID 10 Install on 4 Disks :)

Computers Early days:
ZX Spectrum(1982) , HP-150 MS-DOS(1983) , Amstrad CPC464(1984) ,  BBC Micro B+64(1985) , My First PC HP-Vectra(1987)
 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
How comes it now automatically shows up on my desktop?
Right click on desktop, choose Desktop Settings, Icons tab, select what you want to show/not show under Default Icons.

And I notice that while I can now get at the network directory from the dialog that pops up from a web page, it's not the same dialog (Thunar?) available from the Linux accessories?
No big deal, you have it working, I'd be just happy :)
 

 

Richard

  • Guest
Dear Valtam,

Just the trick! Thanks very much. A couple of points/questions if I may...

1. I used to do some work on Solaris systems. Its file system file was called vfstab - probably the reason for my earlier typo!

2. I think I understand that we've created a file system mount point and pointed it at a remote directory. But (just out of interest) how comes it now automatically shows up on my desktop? And I notice that while I can now get at the network directory from the dialog that pops up from a web page, it's not the same dialog (Thunar?) available from the Linux accessories?

Many thanks again.

Richard
 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
You can't have any gaps in the share name.
//springfield2/springfield2-d/eBay Pictures/ /home/richard/eBayPics/ cifs users,credentials=/home/richard .creds,workgroup=RICHARDS,ip=192.168.1.8 0 0

Change the share name on the windows pc to ebaypics, will be better, then change the fstab file on Linux Lite to match.
 

 

Richard

  • Guest
Dear Valtam,

Must have been a typo in my reply to your original posting - I was referring to 'fstab' (not vfstab).

Richard
 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
Please go over the instructions very carefully. There is no 'vfstab' file it's fstab.
 

 

Richard

  • Guest
Dear Valtam,

Thanks ever so for your reply. I've done exactly as in your instructions (including checking that my edit of vfstab is correct!) but when I run the mount command I get an error message"line 13 in /etc/vfstab is bad". This is line 13...

//springfield2/springfield2-d/eBay Pictures/ /home/richard/eBayPics/ cifs users,credentials=/home/richard .creds,workgroup=RICHARDS,ip=192.168.1.8 0 0

(it's all on one line).

Any ideas.

Many thanks.

Richard

 

 

Jerry

  • Linux Lite Creator
  • Administrator
  • Platinum Level Poster
  • *****
  • 8778
    Posts
  • Reputation: 802
  • Linux Lite Member
    • View Profile
    • Linux Lite OS

  • CPU: Intel Core i9-10850K CPU @ 3.60GHz

  • MEMORY: 32Gb

  • VIDEO CARD: nVidia GeForce GTX 1650

  • Kernel: 5.x
The best way to tackle this is to add a network location to Thunar (the file manager) that way whenever you need to attach a file, the option will always be shown. Before starting, make sure you have set up the folder on Windows that you want to share on your network.

1. On your Linux Lite machine, create a folder in your home folder called 'picshares' for example.



2. Go to Menu, Accessories, Text Editor. Enter the following contents:

Code: [Select]
username=yourname
password=yourpass

where yourname and yourpass is your username and password on the Windows machine for the share.
Save the file in your home folder as '.creds' don't forget the dot infront of creds!

3. Open a terminal and do:

Code: [Select]
sudo cp /etc/fstab /etc/fstab.bak
4. Then in the same terminal do:

Code: [Select]
sudo leafpad /etc/fstab
5. Copy the following line to the bottom of the fstab file:

Code: [Select]
# Picture Shares
//windowsmachinename/sharename /home/user/picshares cifs users,credentials=/home/user/.creds,workgroup=workgroup,ip=192.168.0.2 0 0

lets break that line down:

windowsmachinename: The name of your Windows machine
sharepath: the name of that Windows share
/home/user/picshare: the path and name of the folder we created in Step 1.
credentials=/home/user/.creds: the location of the credentials file we created in Step 2 (.creds) user = your user on Linux Lite.
workgroup=workgroup: the workgroup name on Windows
ip=192.168.0.2: The ip address of the Windows machine

CAUTION: you MUST be careful when editing the fstab file, any typo or mistake will render your pc incapable of booting properly. Check, check again, then triple check before saving that file. Make sure you also leave a spare blank line at the bottom of the file.

So your fstab file will end up looking something like this:

Code: [Select]
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda1 during installation
UUID=18212f58-251f-480d-8858-d6c6b054b717 /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda5 during installation
UUID=a7ab352a-2750-4668-9a76-785536abeeb8 none            swap    sw              0       0
# Picture Shares
//windowsmachinename/sharename /home/user/picshares cifs users,credentials=/home/user/.creds,workgroup=workgroup,ip=192.168.0.2 0 0

If everything went well, the share should auto mount straight away in Thunar. If it doesn't, open a terminal and do:

Code: [Select]
sudo mount -a
You should now be able to browse to the image from eBay, or any other website.
Tested and confirmed working in Linux Lite 2.0
 

 

Richard

  • Guest
I've just installed LinuxLite on a PC connected to my small Windows workgroup network.  Accessing files from the Windows PCs seemed to work without the need to go through any set up routine. I can see Windows files and transfer them to the Linux box via File Manager.

However, when using eBay to sell an item, when I open the 'attach pictures' dialog, a file access dialog box is opened but it
doesn't show network file access options. When using a windows box (which is what I'm used to doing) this file access dialog box is identical to Windows file manager and gives me access to networked file storage. Can anyone shed any light on this.

Many thanks.

Richard
 

 

-->
X Close Ad

Linux Lite 6.6 FINAL Released - Support for 22 Languages Added - See Release Announcement Section