CIFS Share Question

kjparenteau

Explorer
Joined
Jul 13, 2012
Messages
70
I have searched for quite a while and no luck so far to resolve the issue.

I have a CIFS share set up with anonymous access according to THIS DOC (this share does not need credentials). The issue I am facing is that as soon as I go into that share, I see the following files...

.cshrc
.login
.login_conf
.mail_aliases
.mailrc
.profile
.rhosts
.shrc​

I understand that this is part of Linux and Samba, etc., however I did read HERE that I could set "Homes auxiliary parameters" with "hide dot files = yes" and it should hide those files if I am understanding correctly. I have attempted to set this, as well as in the "auxiliary parameters" section, each time rebooting the server, etc., and the files still remain.

Is there a way to hide these files in the CIFS share? Any assistance would be greatly appreciated.

Thank you,
Kevin
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
In your GUI under Sharing --> Windows (CIFS) Sharing --> your shared item, edit the share, do you have "Show Hidden Files" checked? If yes, uncheck it. I don't know if you need to restart the CIFS service to force the change or if it's immediate. See if that works for you.
 

kjparenteau

Explorer
Joined
Jul 13, 2012
Messages
70
Thank you for the response. That option is indeed unchecked, and the files still show. Do you have any other suggestions that might help?

Thank you,
Kevin
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
What is the Path that you have defined in the Windows (CIFS) Share? I'm not a knowledgeable person with respect to group and file permissions but I make due when there is a need. My Path gos to a specific subdirectory in my pool, one of them is '/mnt/pool/Data' and I cannot see any hidden files when I look at it via Windows 7.
 

kjparenteau

Explorer
Joined
Jul 13, 2012
Messages
70
Okay I think you kicked it into the right direction! I had the volume and CIFS share mounted to the same location. I'm assuming something with the group, owner, or home directories was why the files were there in the first place.

But I used the CIFS share mounted to the home folder to create a subfolder called "Share" and then I went into the CIFS share and remounted the share to that subfolder. Now I do not see the files in question. :)

My next question... Is there a way to create a subfolder without having to go the round about way that I did? Because I'm sure it's just my lack of linux knowledge or FreeNAS knowledge that made me not realize something super simple I'm sure.

Thanks for the tip joeschmuck!
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
That is easy enough...

Open up the shell (Either in the GUI or Console or SSH), I'd just use the GUI (Left hand pane). This will open a window. The commands you should become familiar with are: cd, pwd, ls, mkdir.
cd = Change Directory
pwd = You Current Working Directory
ls = List Files/Directories
mkdir = Make Directory

So once you are in your shell you can type 'pwd' and list where you are. You will want to type 'cd/mnt'
The type 'ls' and you should see your pool name. Next type cd and your pool name. Do another ls to see the directories there. At this point you could create a directory in your pool and here is an example.
'mkdir Data' and the type 'ls' again to see it created. Now you can type 'exit' to leave the shell and then mount that 'Data' directory for sharing.

I understand how difficult it is to get into a new operating system but if you have any knowledge of Windows DOS commands, then the Unix/Linux type commands will not be difficult to grasp. But there are a lot of things I have difficulty with because I rarely use Linux commands, simple things like 'grep' which is a powerful command and redirection operators.

Hope this helps,
-Mark
 

HolyK

Ninja Turtle
Moderator
Joined
May 26, 2011
Messages
654
These files are here if that path is also $HOME of some user.

With aux parameter "hide dot files = yes" Windows will just take ".dotted" files as "hidden". But if you have "Show hidden files, folders, or drives" set in your windows, you will simply see these "hidden files".

If you want to get rid of these files (i mean HIDE them), just edit that specific CIFS share and add following AUX parameter

Code:
veto files = /*.cshrc/*.login/*.login_conf/*.mail_aliases/*.mailrc/*.profile/*.rhosts/*.shrc/


Now restart CIFS service and you should not see these files from your windows machine anymore :]
 

B2SAspecT

Cadet
Joined
Jun 8, 2020
Messages
1
hello, i know i am about 7 years later, but i have the same problem but only trough ftp server. i don't see the files on windows, but when i log into the ftp (with any user) i see the files
 
Top