?
Solved

samba files are hidden

Posted on 2004-08-17
7
Medium Priority
?
906 Views
Last Modified: 2012-06-21
hey everone

First off, im new to linux

i have a samba file server which is providing files to all window machines.

and after setting up the smb.conf

all of the shares are accessable but all of the files are hidden for all users

and the only way to see them is to show hidden files in windows

how do i stop this from happening in the future

and also convert all of the current files on the server not to be hidden again

thank you

kevin
0
Comment
Question by:krazieintent
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 40

Accepted Solution

by:
jlevie earned 400 total points
ID: 11822457
Unless you've specifically listed files files to be hidden in your smb.conf share definition via one of the "hide" directives in the share definition what files will be hidden are determined via the normal rules on a windows client. The smb.conf directives that can cause files to be hidden over and above what the clinet would normally hide include:

hide dot files (S)
              This is a boolean parameter that controls whether files starting
              with a dot appear as hidden files.
                                                                               
              Default: hide dot files = yes
hide files (S)
              This is a list of files or directories that are not visible  but
              are  accessible.  The  DOS  ’hidden’ attribute is applied to any
              files or directories that match.
                                                                               
              Each entry in the list must be separated by a ’/’, which  allows
              spaces  to  be included in the entry. ’*’ and ’?’ can be used to
              specify multiple files or directories as in DOS wildcards.
                                                                               
              Each entry must be a Unix path, not a  DOS  path  and  must  not
              include the Unix directory separator ’/’.
                                                                               
              Note  that  the  case sensitivity option is applicable in hiding
              files.
                                                                               
              Setting this parameter will affect the performance of Samba,  as
              it will be forced to check all files and directories for a match
              as they are scanned.
                                                                               
              Default: hide files = # no file are hidden
hide special files (S)
              This parameter prevents clients from seeing special  files  such
              as sockets, devices and fifo’s in directory listings.
                                                                               
              Default: hide special files = no
hide unreadable (S)
              This  parameter  prevents  clients  from seeing the existance of
              files that cannot be read. Defaults to off.
                                                                               
              Default: hide unreadable = no
hide unwriteable files (S)
              This parameter prevents clients from  seeing  the  existance  of
              files  that  cannot  be  written  to. Defaults to off. Note that
              unwriteable directories are shown as usual.
                                                                               
              Default: hide unwriteable files = no
                                                                               
Other than "hide dot files" the default is off, so any files not visble on the client are hidden by the windows client rules, not the server.

Could you show us an example of what's being hidden and what the results of 'grep hide smb.conf' are?
0
 
LVL 22

Expert Comment

by:pjedmond
ID: 11822464
Try this as a samba share profile (from smb.conf) - Designed to ensure that all files are visible:

[general]
        path = /home/general
        comment = General Folder
        writable = yes
        force directory mode = 766
        force create mode =766
        create mode = 766
        directory mode = 766
        delete readonly = yes
        guest account = general
        wide links = no
        public = yes
        guest only = yes


As for invisible files - if the files begin with a '.' period, then they are treated as hidden files, so the default .basrc, and other files from skel to a home directory are also invisible, unless you set  Tools->Folder Options in windows to view the endingd after the '.'

The = 766 lines are the ones that force visibility and accessibility, but not that they may be far too general for your requirements and you may need to limit that a bit. This share is effectivily accessible by everyone, but it gives you a good place to start.

HTH:)
0
 
LVL 22

Expert Comment

by:pjedmond
ID: 11822522
Perhaps you might wish to try SWAT or Webmin to try configuring your shares?
0
Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

 
LVL 3

Author Comment

by:krazieintent
ID: 11822549
well i was just messing with the server and under each directory i added map hidden= no

and that seemed to clear everything up

but thanks for the help

- Kevin
0
 
LVL 1

Expert Comment

by:bestondoa
ID: 11843456
Hello,

I think the points should be awarded to jlevie for is work and effort. Although the solution wasn't exactly what jlevie mentioned, he pointed in the right direction and helped in some way to the solution.

Cheers,

Bestondoa
0
 
LVL 22

Expert Comment

by:pjedmond
ID: 11844163
You shouldn't need to add map hidden = no, unless there is something in the 'generic' part of the smb.conf file that makes it hidden in the first place. (But I agree that jlevie provided the most useful pointer)
0
 
LVL 3

Author Comment

by:krazieintent
ID: 11845696
thank you all for your insight on this and due to popular demand jlevie gets the points

but again thank you all :)
0

Featured Post

What is a Denial of Service (DoS)?

A DoS is a malicious attempt to prevent the normal operation of a computer system. You may frequently see the terms 'DDoS' (Distributed Denial of Service) and 'DoS' used interchangeably, but there are some subtle differences.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question