Red Hat / Fedora :: Permissions With CIFS Share And Rsync
Jan 28, 2011
am trying to sync data from Server A to Server B. The destination on Server B is a CIFS share and I need to preserve timestamps, permissions, etc. on all the data that I transfer. During the rsync process, I receive thousands of errors like the one below:
rsync: chown "/LBDCASAN001/JasonHarper/files/1259810304676/2010-12-22-01-00-03/0x22/0xc8/0x43/0x0a" failed: Permission denied (13)
I'm not sure if it's related at all, but my mount point on Server B has the permissions set as: drwxr-xr-x 2 root root when it is unmounted. When I mount the CIFS share, the mount point permissions change to: drwxrws---+ 3 root root
Also, here is the line from my /etc/fstab that mounts the share:
//X.X.X.X/LBXXXXX001 /LBXXXXX001 cifs username=LBXXXXX001,password=XXXXXXX!,uid=0,gid=0 0 0
When I perform the rsync, I'm authenticating to Server B from Server A as root.
Following instructions that I received from the Fedora 10 Guide, I recently edited my etc/fstab file so that I could auto mount my Windows share. It worked the first time, but when I rebooted, I noticed an error saying that Linux could not not unmount the cifs shares. Eventually it did reboot, but now I cannot mount the share at all from fstab. When I run the command #mount -a and then #mount, my share is shown to be mounted although I cannot access it and there is no link to it on the desktop like there was the first time it mounted. I basically want my Windows share to be permanently mounted with read/write permissions. My Distro is Fedora Core 10 64 bit. How can I resolve this issue?
i switched from sabayon to Fedora13 some days ago, and now i encounter the problem, that some applications (XnView, XnViewMP, PFTrack so far) can't browse cifs network paths.This was working fine while on Sabayon.
Problem: permissions for rsync and BackinTime. Setup: Ubuntu 11.04, Two internal HD, #1=main, single boot, #2=backup drive. Question: How do I set up my 2nd HD with correct permissions? Background: I had previously a dual boot XP+10.04 with a 2nd HD formatted as NTFS. With this I was able to use my rsync and backintime to my 2nd HD with no issue. My new set up is EXT4 on both HD.
(I even tried to reformat my 2nd HD as NTFS, but that didnt fix the issue) I followed [URL] to mount the 2nd HD and get permissions. But now when I run backintime i get this error: [E] Error: rsync: opendir "/home/myhome/.ssh" failed: Permission denied (13) I did my requisite reading for a newbie, and am stuck. I ran backintime as root, and it backed up ok. How do I run my user version of backintime? (i.e. How do I fix the permission issue?)
I have looked at a LOT of forum posts and other sites trying to solve this problem but I have had no luck. I've seen the following:[URL].. I have an entry in my fstab that lets root mount a samba share on a Windows Server 2003 machine and gives users full read/write access to the share. The fstab entry looks like:
Code: //servername.net/share /mnt/share cifs rw,user,umask=000,username=someuser,noauto,file_mode=0777,dir_mode=0777 0 0 However, when a normal user tries to mount the share they get one of two errors: 1. If I have /sbin/mount.cifs set to 777 Code: mount error(1): Operation not permitted Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) 2. If I have /sbin/mount.cifs set to +s
Code: mount error: permission denied or not superuser and mount.cifs not installed SUID Does anyone have any suggestions as to how I would go about getting a user able to mount this samba share?
I am trying to image about 30 laptops with WinXP, and I am using Clonezilla and DRBL for the task. We will start migration to Win7 starting Q4, so for now we are still using XP. I used a Clonezilla live USB to capture a standardized image to a CIFS/SAMBA share on the enterprise file server. The file server does not support NFS. To deploy the image, I used Virtualbox to build a VM with Centos 5.5 and then later Ubuntu 10.10. I mounted the CIFS share to /home/partimag but I found that I cannot share this CIFS mount out as NFS so I was unable to deploy the image with the image still residing on the CIFS; I had to copy the image to the VM's local drive.
Now using the DRBL live distribution, which is Debian based, I was able to obtain the image from a CIFS share and then share it out to the clients to be imaged as NFS (I think). I was able to use the DRBL live for some older computers, but since that hasn't been updated in nearly 2 years, I think it's missing some device drivers for my newer machines so it doesn't work on them -- this is why I looked at using CentOS and Ubuntu. To mount the CIFS shares, I'm using the following command:
mount -t cifs -o user@domain //share_ip_addr/share_name/folder /home/mount_point
Do I need to do something different to enable the mounted CIFS share to be shared out as a NFS share so that the clients to be imaged can see the contents from the CIFS share as a NFS share? The below image depicts my setup. The workstation has two NICs. The 10 network is the enterprise network and the 192 network is for DRBL imaging only. DRBL/Clonezilla does PXE boot and leases DHCP for the laptops. The laptops are shielded from the enterprise LAN; I am not doing any kind of NAT on on the server. The Linux VM is built with dual NICs and are set to bridged mode so they appear to be a separate NIC from the VM host on the network even though they going into the same port on the wall. [URL]
I just made the upgrade to 10.04 over the weekend, and everything seems to be working fine, minus one nagging detail.I have a Mythbuntu setup - a frontend and a backend. In addition to recording television, I have a folder setup on my backend where I can dump movie files to watch on the frontend. The folder is shared in the /etc/fstab via a CIFS share. Within that folder is a symlink to where my torrent folder is located. The issues seems to be how my frontend handles symlinks within the shared folders. If I run "ls -la" in my base CIFS share folder, it lists the symlink folder and says it's owned by root, but if I try and change to that directory - either using "ls" or "cd" - it says Permission Denied. On the backend, I changed ownership of the symlink to the username the CIFS is using to login, but that had no effect. I'm not familiar with how to do any sort of configuration on CIFS, if that's where I'd even need to start.
I have a FreeNAS server running CIFS shares. I just tried out Deja Dup on my home directory and backed it up to my CIFS share. This is about 200gb worth or so, I believe.After it was done, I went to browse into the directory. I've restarted the CIFS service on the server, rebooted the server, and rebooted Ubuntu,I STILL cannot browse my directory. It says:Sorry, could not display all the contents of "jason": Invalid argument.Yet I can SSH into it and do an ls listing and see all of the .tar.gz packages that Deja Dup created. Likewise, I can browse to it just fine in Windows.What is Ubuntu doing that it doesn't like to see these files? It's a huge, huge pain in the rear... How can I fix it?
I've got a Fedora 10 server with a simple read-only samba share.I'm able to mount and browse the share from a Fedora 12 client, but all directories appear as empty--and I can see on the server that they contain many files. This happens whether I browse using smbclient, or mount using mount.cifs.I've got smb/nmb ports enabled on both the client and server. File permissions on the server look right.The server smb.conf setup:
How can I set permissions for users within the share? Example: I have a share called Programming and some user can create folders within it most others can not, can read the documents. How do I set permissions?
I have a Buffalo Drivestation (model HD-CELU2, 1tb) attached to my network.From my ubuntu desktop I can go to the menu, select "connect to server", put in the ip and share info, and it mounts perfectly.I can open the share and browse eadwrite, but when I try to mount it from a terminal or within fstab, it will still mount, but I cannot see any files that are on the drive. I have about 12gb of data on it, but like I said when I mount it using "mount -t cifs 192.x.x.x/share blah blah blah" I do not see any of the files.If I do a df I can see that the drive has files on it based on the free space available, but if I do an ls nothing shows.
Trying to figure out if there is a way to connect to a cifs share, and only being prompted for one password? ie using the following:
sudo mount -t cifs //goanna/neddy -o username=neddy,iocharset=utf8,file_mode=0777,dir_mode=0777 /mnt/neddy prompts twice for a password (sudo & the share password). Is there anyway to "catch" the sudo password for the connect? (Long shot!
I have a network share mounted with cifs which does not work as expected. It should automount at boot and dismount at shutdown. It does not automount at boot, but "# mount -a" will mount it in the gui after booting finishes. This I can live with, but at shutdown or reboot, the cifs share hangs for about 30 seconds before dying. My /etc/fstab entry code...
I saw a bug report about the cifs umount issue, but can't find it at the moment. I did notice that it was a very old bug. If I remember to do "# umount /media/data-srv" before rebooting, all is fine, but I seem to constantly forget and then stew as the system hangs for an extra 30-45 seconds. I've tried several things to automate it including shutdown scripts added to /etc/init.d/ and elsewhere, but nothing seems to work. Anyone have this issue and find a work-around?
I've to make a Windows 2000 share on my Server Linux CentOS 5.1 with all the updates installed with yum. I've a directory on a Windows 2000 that contains some images for a catalogue. I have my internet site on CentOS 5.1 with a Apache - Mysql - PHP web server. I have to mount my directory on a share in /mnt/catalogueimages and made a symbolic link from my /var/www/html/mysite/catimages to this samba share.
This is what I do following your guide a this link: [URL] I have placed in my /etc/fstab this line: //SERVER/C/Catalogue /mnt/catalogueimages cifs user,username=Administrator,password=,uid=apache,gid=apache 0 0 My Windows 2000 server have no password.
After that I made the symbolic link: ln -s /mnt/catalogueimages /var/www/html/mysite/catimages All it's OK.
The problem is that I can't see the images via browser. I have tried also to put some images in the directory /mnt/catalogueimages, deleting the mount point, in order to see if the problem was in apache: the images are visible via browser. Why I don't reach to see the images mounted with samba?
We recently moved to a new home and I am trying to get my home file/print server set up again. Thanks to swerdna's excellent website, I got my server box (just upgraded from 11.0 to 11.2) running Samba and serving my shares over the network, and my "client" machines can access them without a problem.However, I'm not having much luck setting up CIFS mounts on my Linux desktop. I have my all-purpose user added to the Samba auth list (via smbpasswd), and configured my client as swerdna's howto's specify, and I can access the files just find. However, when I try to mount the shares with this command:
Code: mount -t cifs -o username=klein,password=klein //192.168.1.70/sharedmedia /home/zak/SharedMedia/ I get the following error:
I have a Hitachi SimpleNET adapter (entry-level NAS device) on a Seagate FreeAgent 1TB external HDD (formatted ext3). The NAS device is connected over 100MB/s ethernet to a Netgear Wireless G router. All other devices connect using Wireless G. The NAS runs embedded Linux on an ARM processor and it runs vsftpd and Samba for file transfers.
If I transfer a large file using an FTP client the transfer maxes out at around 2.5MB/s. For my purposes that's good enough, especially considering the Wireless G bottleneck. If I transfer a file from a Windows 7 client (using samba) I get around 2.2MB/s. I know the CIFS protocol has more overhead than FTP and the difference in speed isn't that noticeable.Any combination of Ubuntu and Samba results in me getting less than 1MB/s. I've tried mounting it through Nautilus (GVFS) and /etc/fstab. FTP from this same Ubuntu client gets around 2.5MB/s.
I don't have root access on the SimpleNET to change the smb.conf. I've made a few adjustments to the mount options with no success. how to either speed up 10.04 as a Samba client or mount a folder on an FTP server locally? I've tried both curlftpfs and FUSEFTP. With curlftpfs any write operation results in an I/O error and it crashes intermittently. With FUSEFTP I never got that far and couldn't even browse the folder.
When using the following cifs mount command, mount -t smbfs -o username=username,password=password //srv/shr /usr/localfolder/and the cifs share does not exist, localfolder is mounted like d????????? ? ? ? ? ? localfolderafter a number of time , when umounting we get a kern <soft lock>Is there any way to fail the mount if the destination share does not exist, ive had a quick look through man mount but can not see a solution.
I'm trying to mount some CIFS shares (NetApp) to my Ubuntu 11.04 desktop (64-bit).I am mounting it as a domain user with admin rights and full control over the share.ter mounting it as root, all the files are owned by root and I can't modify them from my non-root user.Here is how I am mounting the share:
mount -t cifs -o domain=example,username=example-user,password=mypassword //myfiler.example.com/myshare$/mydir /mnt/myshare/
This share is a qtree under a volume with security type set to NTFS. (Although I have also tried security type = Mixed) We don't configure user-level access to shares on the filer, we create directories and lay down permissions on those from the Windows side. (Although I have tried explicitly adding my domain user to the access list for the share)
I've been trying for a while mounting a EMC NAS share on linux. As far as I know the NAS share behaves just like a regular windows share, so the mount process should be very similar. On the NAS server, the disc "Disc1" is shared, and I need to mount a sub-subfolder of that share. This is my line in /etc/fstab:
I'm trying to setup a samba server to share data among clients via cifs. As a test, I mounted the samba share on the same machine and tried to access the contents of the directory. The mount command was:mount -t cifs -o username=sthomaso,workgroup=WORKGROUP //server/scratch /mnt/server/scratch..which worked fine after entering the password. Although I can "cd /mnt/server/scratch", when I try to list the contents of the directory with "ls", I get error "ls: reading directory .: Permission denied".
We have a homegrown process that runs on a windows box and produces a csv file. We mount the directory these are output to using autofs/cifs and then process them using a program on our linux database servers.
Is there a way from linux, looking at the cifs share, to tell if the target file is currently in use by a process on the windows box? We are having issues where an incomplete file is being processed occasionally.
I try to connect my Debian Jessie to my Windows share
This is what I have done:
-> 1 - create an .smbcredentials file located in my /home directory (with account / password and domain) -> 2 - implement /etc/fstab with information like that : //192.168.x.x/Animes/media/Animes cifs uid=toto,dir_mode=0777,file_mode=0777,credentials=/home/.smbcredentials,iocharset=utf800
and when I try to go on my windows share, I have this message:
An error occurred while accessing 'Home', the system responded: mount: only root can mount //192.168.x.x/Audio-Video-01 on /media/Audio-Video-01
I think about one thing, if uid=toto is different in fstab than my current debian account session name, it is possible the problem came because of that?
I need to mount a windows share on my OpenSUSE 11.3. I get it using the mount.cifs command (by itself or using cifstab), but only root can rw file. I try the uid/gid parameters (also using forceuid) and the file_mode/dir_mode parameters, but I get the same behavior: all files and directory with rwxr-xr-x permissions and root/root (user/group). I read the whole section FILE AND DIRECTORY OWNERSHIP AND PERMISSIONS in man mount.cifs but nothing works.
Using Dolphin in Super-User mode, I can copy files and directories from the share to itself with no errors. Using Dolphin in Normal-user mode. I get the failure "Could not change permissions for...". The file is copied, but its owner,timestamp and permissions are wrong. If a subdirectory is involved, the copy aborts.
Using Windows XP I can copy files and directories from the share to itself with no errors.
Testing: If I mount with uid and gid, then my normal user can not access the share. mount.cifs //10.x.x.x/Data /home/stevej/Synology/Data/ --verbose -o user=stevej uid=stevej gid=users
Synology DS211 - There are 2 users on it. One of which is stevej and the other is julie. Rights RWX are applied to the users and the group called users. All files have stevej as the owner and users as the group with RWX Opensuse 11.4 - There are 2 pc's. One is run as stevej. The other pc runs as julie Windows 2000 - Runs as stevej and maps to the share as stevej.
Works as expected Windows XP - Runs as julie and maps the the share as julie. Works as expected Ultimately, I want the shares to automount at boot, or login and give the user full access. I have been to Swerdna's page and done as much as I can, but still no luck.
There are a number of shares on the destination system; for the purposes of this thread I used D$ and F$ (corresponding to those partitions). These shares are mounted permanently via CIFS (entries in fstab) on the source system.Today I copied an ISO image of some 3.5 GB from source (S) to destination (D). md5sum on S gave a different checksum for the source ISO than that calculated by HashCheck Shell Extension for the destination ISO. I know some would argue that I shoud use the same md5sum programm for both images.
To circumvent that I 7zipped the ISO, verified it's integrity and copied that archive from S to D. Verification of the acrchive by the Win version of 7z failed.To see if it's a protocol problem I copied both ISO and archive of ISO to another D this time using sshfs (it's an Ubuntu server). Flawless copies.Then I copied both files to another Win-based server on the same network. Flawless copies.Mystified, I checked the partition's file system integrity (NTFS) where the errors occured. Minor inconsistencies (no errors according to chkdsk). So I copied both files again, once to another partition (D:) of the original D, once to that partition causing the error in the first place (F:).
(D:): archive corrupt, checksum okay (F:): this time around both okay.
What the hell can I do to nail down the problem?! I don't even know whether it's a problem of the source system or the destination.
I'm using cifs to mount windows share.I have created one credentials file and given the path in fstab to mount at boot time. Now i want to encrypt the credentials file and place that in the fstab file.But it is not accepting.. how to use encrypted file to use in fstab,so that normal users can not watch the credentials inside the file.
I've got my Samba shares up and running. I can stream files from the server, I can create files on the server, and I can copy files from the server.
Running a Windows program (from a Windows box) directly from the Samba server, however, is turning into a nightmare. I'm getting Access is Denied errors from the Windows box, yet I can copy/create/etc from the entire directory with no problems.
Are there any special permissions I need to run EXE files from a Windows box, located on a Samba share? I've already chmod'd everything to 777, and I show full access when ls -Z is used.
I followed this howto in order to mount CIFS shares on demand. This works great, however, this guide suggests leaving my network passwords unencrypted on the disk. This is a very bad security practice, as the passwords can be easly retrieved by booting the computer using a different OS.
I was looking for a way to secure things up, so I came up with this solution: Instead of storing the passwords plain text on the disk, I store them in a tar file encrypted using GPG. When I boot my system, I open this file to a directory in /dev/shm, and order AutoFS to retrieve the passwords from there.
This does the trick, but I presume this solution is not that secure, since /dev/shm content can be written to the swap partition. Is there any other solution which is a better security practice? Maybe using some sort of keyring service?
I'm trying to learn how rsync works to backup my system. I tried: Code: rsync -azvv /home /media/Elements I get a folder called home on my external hard drive but when I use ls -l to see the permissions they are all wrong. On my /home folder the permissions for /nathan are drwxr-xr-x 48 nathan nathan The permissions on the backup /nathan folder are drwx------ 1 nathan nathan
I also tried using the long version of -a which is -rlptgoD and that didn't work either. What do the 48 and 1 mean when I used ls -l? When I look in the /nathan folder the permissions are all screwed up too. A lot of the files are backed up as executable and the permissions are all screwed up. I also ran it with sudo, and that didn't work either. The permissions were still screwed up and ownership is messed up too.
I know rsync generates a lot of questions, but I have not found an answer to this one about whether the archive option (rsync -a) ever misbehaves. I am transferring data from field instruments running Debian etch to a central server running Debian lenny. My command is below: Code: rsync -av --remove-source-files --log-file=rsync_20110612_0656Z.log ./20100616/ archive@bigserver:/mnt/ZAP_DATA/20100616/zap2/
After rsync runs, the directories it touches on bigserver have very strange permissions as follows: Code: d-wxrw--wt 2 root root 4.0K 2010-10-26 04:31 20101026
This says that directory 20100226 can be written by anybody, but can't even be read by its owner! I thought rsync was messing things up, but in the process of writing this question I discovered that the original files that I am trying to sync have these crazy permissions. So I no longer have a question, but if future LQers think that rsync -a is messing up their permissions, this post may confirm that it is merely copying their messed up permissions from somewhere else, as it is supposed to do!