I would really appreciate someone helping me access files that are held on a file server running OpenSUSE 10.3. On that machine I can access them fine - although the appropriate application is not installed. Problem is when I try to access them over the LAN from a Windows Vista PC. This used to work fine but now although I can browse to all folders and see the files, if I try to copy/paste nothing happens. If I try to launch any file (e.g. .JPG, .PDF, .DOC) the appropriate application launches and says that access is denied or the file is already open elsewhere.
My knowledge of OpenSUSE does not extend to checking file permissions. I am not aware of anything changing since this last worked. I have restarted both computers. Thanks for getting this far at least
You first need to describe how the files are shared…
Is this a network share?
Is this a web or ftp share?
Something else?
Then you need to describe what type of network security exists, is there an LDAP or AD or other Domain security?
You then may need to know whether other clients successfully connect or not.
In general, there are file permissions and there are file share permissions, both need to be addressed before you have access.
And, next time when possible always include the <exact error> (copy and paste if possible) in your post to further minimize guessing.
This is a network share on one PC. On another computer with exactly the same problem I just open Windows Explorer and browse through to the folder containing the file I am interested in. There is no domain or active directory, just a simple workgroup of two Windows PCs and a Linux file server.
On the server I am logging on as root and can access all these although the applications to open them are not present.
openSUSE 10.3, wow, that machine served for a long time. We could try a few diagnostic things. In the command line console what do you get when you run these commands:
smbtree -N
That should show the network as seen from openSUSE That should set the groundwork. Then check that name resolution is still Ok with this command (run as root):
rcnmb status; rcsmb status
I think that was the CLI test back in the days of 10.3, can’t quite remember
And this command should let us look under the bonnet:
testparm
and finally this test to see if there is a name lodged in the samba member database, run as root:
pdbedit -L
So please return those data and we might be able to look at it in some depth.
Check with AppArmor (YaST > Security and Users > AppArmor Configuration). Try to access the Samba share with AppArmor
turned off. If your share(s) work now, you need to adjust the AppArmor profile for Samba.
–
P.V.
“We’re all in this together, I’m pulling for you” Red Green
What are the permissions on the directory /home/common.
ls -ld /home/common
For the sake of us that use nntp to access these fora, please just cut and paste from the terminal to your post and use
code tags. the use of the intermediate “dropboxusercontent” makes your posts difficult to read.
P.V.
“We’re all in this together, I’m pulling for you” Red Green
Also DadtDick please tell us which share you are trying to access, is it the share named “common” or is it for files in one of the home directories like the home directories of janice, toby, chris and so on? Which shares please are causing trouble.
I might add (ok I will add, why do we use that silly expression) – please also note that you have this machine set up not as a workgroup, although it might also work ok as a workgroup.
So answer this: are you using it as a “workgroup” or as a windows style logon-to-server?
Thanks to those who have taken time to help. I will type the outstanding commands in once I have access to the computer on Monday. I will also try to copy/paste the output (assuming I can find a text editor) rather than screenshot images.
When I said this was a workgroup, what I meant was it is not a domain. It is just a place to host files that the two Windows PCs access. All files of interest are under the Common folder structure.
On 10/18/2014 9:26 AM, DadtDick wrote:
>
> Thanks to those who have taken time to help. I will type the
> outstanding commands in once I have access to the computer on Monday. I
> will also try to copy/paste the output (assuming I can find a text
> editor) rather than screenshot images.
>
> When I said this was a workgroup, what I meant was it is not a domain.
> It is just a place to host files that the two Windows PCs access. All
> files of interest are under the Common folder structure.
>
DadtDick;
You do have Samba3 setup as a NT-style Primary Domain Controller (PDC) but that should not be causing your current
problem. Did you try to disable AppArmor for testing purposes? If I recall properly, 10.3 had AppArmor but it is likely
listed as “Novel AppArmor” in the main menu of YaST. When I wrote my addenda I had forgotten you were using an
antediluvian version of openSUSE.
If you are posting from openSUSE you should be able to simply cut in the terminal, <ctl>+<shift>+C, and then paste
directly into your post. If you are posting from a different machine, pipe the result to a text file and then move that
to the machine you post on. e.g.
ls -ld /home/common > myresults.text
–
P.V.
“We’re all in this together, I’m pulling for you” Red Green
At the initial Termainal prompt I was not able to get /home/common recognised so I CDed to it then ran the ls command to get the following output
drwxrwx--- 10 root Common 4096 2014-10-20 14:10
I then went to test toggling AppArmor off so on the Vista PC I tried to access the server but it was not visible to the network (unlike when I did this last week). I thought a restart of the server may help to I clicked through to the ‘restart’ option which took me to the logon screen but mouse/kb were not usable - the machine had hung. The only way I could progress was to abruptly disconnect power.
When the server came back it was visible on the network and I could go down one level. But when tried to open the /Common folder I got a window telling me that it is not accessible. After that I went to the server, switched AppArmor off and tried to access it again but got the same result.
On 10/20/2014 9:06 AM, DadtDick wrote:
>
> At the initial Termainal prompt I was not able to get /home/common
> recognised so I CDed to it then ran the ls command to get the following
> output
>
> Code:
> --------------------
> drwxrwx— 10 root Common 4096 2014-10-20 14:10
> --------------------
>
>
> I then went to test toggling AppArmor off so on the Vista PC I tried to
> access the server but it was not visible to the network (unlike when I
> did this last week). I thought a restart of the server may help to I
> clicked through to the ‘restart’ option which took me to the logon
> screen but mouse/kb were not usable - the machine had hung. The only
> way I could progress was to abruptly disconnect power.
>
> When the server came back it was visible on the network and I could go
> down one level. But when tried to open the /Common folder I got a
> window telling me that it is not accessible. After that I went to the
> server, switched AppArmor off and tried to access it again but got the
> same result.
>
> An image of the error windows is at
> https://dl.dropboxusercontent.com/u/30148243/sna.PNG
>
>
DadtDick;
Which username are you using to access the shares? By default Windows will pass the username of the Windows user. Is
that user in the Common group? On Vista can you browse the contents (i.e. see the files) of the share “Common”?
If you’re not sure of the name being passed by Vista, try adding the following parameter to /etc/samba/smb.conf and
restarting smb.
log level = 1 auth:3
You can then check the file /var/log/samba/log.smbd to see how authentication failed (or succeeded). Be careful editing
smb.conf. It needs to be done as root so use kdesu kwrite or gnomesu gedit.
If the user authenticates as expected and you can still not access the individual shares, then perhaps
/var/lib/samba/locking.tdb has become corrupted. Try renaming that file and restarting smb. Samba should recreate that
file when it restarts.
To restart Samba use:
su -
rcsmb restart
–
P.V.
“We’re all in this together, I’m pulling for you” Red Green
There are apparently two users, ann and admin, with UID of 1005 listed in your password tdb. Apparently there was a
name change. If this is the user in question, Windows will continue to pass the old name even when you have changed the
name in Windows. Windows does not actually change a username but just creates an alias. There is away to get around
this on the Linux side. Is this the user in question?
–
P.V.
“We’re all in this together, I’m pulling for you” Red Green
I have been logging on to the Vista PC as user admin and to the Linux server as root. Creating an account named root on the Vista PC would be no problem if you think that’s necessary, and I could create a Common group to assign that user to, although my understanding is that would only affect access rights on the local machine.
I will have to reply later once I have accessed the server to type the commands you list. You say I should do that before “restarting smb” - what is smb ? Is it the same as samba ? And should the su -rcsmb restart command be split over two lines as shown or was the carriage return added for you ?
I think the files we need are all under /Common and I believe the owner of the ann account (who is no more) was previously able to access the files just as other account holder were. Account ownership is moot now as there is only one person remaining.
On 10/21/2014 9:16 AM, DadtDick wrote:
>
> I have been logging on to the Vista PC as user admin and to the Linux
> server as root. Creating an account named root on the Vista PC would be
> no problem if you think that’s necessary, and I could create a Common
> group to assign that user to, although my understanding is that would
> only affect access rights on the local machine.
>
First, you have the parameter “valid users = @Common” in your smb.conf. That means that only members of the group
Common are allowed access to the shares. Either you need to be in the group Common or remove the valid users line from
/etc/samba/smb.conf.
Second, it’s not wise, or needed, to create a user root on Vista.
> I will have to reply later once I have accessed the server to type the
> commands you list. You say I should do that before “restarting smb” -
> what is smb ? Is it the same as samba ? And should the su -rcsmb
> restart command be split over two lines as shown or was the carriage
> return added for you ?
Third, smb(d) is the Samba daemon. There were two commands I gave you that should be on two different lines.
The first “su -” uses root as a substitute for the logged on user as well as root’s environment. (It is not wise to
log onto a Linux machine as user root.) The second command “rcsmb restart” restarts the smbd daemon.
>
> I think the files we need are all under /Common and I believe the owner
> of the ann account (who is no more) was previously able to access the
> files just as other account holder were. Account ownership is moot now
> as there is only one person remaining.
>
Fourth, your Samba password database is corrupt. (Look at the output of pdbedit.) There are apparently two entries with
UID of 1005. One is “ann” and the other is “admin” but ann is no longer a Linux username and this account is invalid. I
think this is correctable but I’m not sure if the fix will help. So now the question is how does Samba see your login
as “admin”. For this we need to see the log entries after you add the “log level” parameter to the [global] section of
smb.conf. In particular if “ann” or some other username, had been the original owner of your Vista account it will
likely be sending that old name and not “admin”.
–
P.V.
“We’re all in this together, I’m pulling for you” Red Green
The reason for the inability to access the server at all turned out to be that the IP addresses were all statically defined to be in a different network from the new router. I was able to modify the /etc/samba/smb.conf file but not test out the effectiveness just yet as I need to figure out how to modify the IP address to be dynamic and didn’t have time today.
This is just to thank contributors for helping. I think the problems are moot now as the old server is to be retired and files copied elsewhere. If things change I’ll be back but I just wanted to express my thanks to those who took the time.