file sharing permission issue involving ssh, cygwin


  1. Posts : 2
    Windows 7 Enterprise 64 bit
       #1

    file sharing permission issue involving ssh, cygwin


    Hi. I apologize if this forum is inappropriate, I do not know if I am having a Unix problem or a Windows problem here. I have two machines, WORKER1 and WORKER2, both running Windows 7 Enterprise 64 bit. I have the latest version of Cygwin and OpenSSH installed on each, and am running sshd from Cygwin on WORKER2. I have a file stored in the default Users\Public folder on WORKER1 that I am having permission issues with and was hoping for some advice on how to fix it.

    I am using Cygwin on WORKER1 to ssh into WORKER2 using public RSA key authentication. Then after doing this I am trying to run a file located in Users\Public on WORKER1. I keep getting permission denied and have run out of ideas. Here is the permissions information I am getting from ls -l and getfacls in Cygwin. The file I am trying to run is Dos_Commands.WORKER2.1.sh:

    Code:
    root@Worker1 ~ 
    $ ssh WORKER2 
    Last login: Tue Jan 31 10:51:54 2012 from worker1  
    
    root@Worker2 ~ 
    $ cd //WORKER1/Users/Public/pMatlab/MatlabMPI/Examples/MatMPI 
    
    root@Worker2 //WORKER1/Users/Public/pMatlab/MatlabMPI/Examples/MatMPI
    $ sh Dos_Commands.WORKER2.1.sh 
    sh: Dos_Commands.WORKER2.1.sh: Permission denied
    
    root@Worker2 //WORKER1/Users/Public/pMatlab/MatlabMPI/Examples/MatMPI 
    $ ls -l
    total 28 
    -rwxrwxrwx+ 1 Administrators None   2 Jan 31 11:01 Dos_Commands.WORKER1.0.sh
    -rwxrwxrwx+ 1 Administrators None 127 Jan 31 11:01 Dos_Commands.WORKER2.1.sh
    -rwxrwxrwx+ 1 Administrators None 250 Jan 31 11:01 Dos_Commands.bat 
    -rwxrwxrwx+ 1 Administrators None 636 Jan 31 11:01 MPI_COMM_WORLD.mat 
    -rwxrwxrwx+ 1 Administrators None  97 Jan 31 11:01 MatMPIdefs1.m
    -rwxrwxrwx+ 1 Administrators None 199 Jan 31 11:01 p0_p0_t10000_buffer.mat
    -rwxrwxrwx+ 1 Administrators None 199 Jan 31 11:01 p0_p1_t10000_buffer.mat
    -rwxrwxrwx+ 1 Administrators None   0 Jan 31 11:01 p0_p1_t10000_lock.mat
    Code:
    root@Worker2 //WORKER1/Users/Public/pMatlab/MatlabMPI/Examples/MatMPI
    $ getfacl Dos_Commands.WORKER2.1.sh
    # file: Dos_Commands.WORKER2.1.sh
    # owner: Administrators
    # group: None
    user::rwx
    user:root:rwx
    group::---
    group:SYSTEM:rwx
    group:Users:rwx
    mask:rwx
    other:rwx
    And then running icacls from cmd.exe yields:

    Code:
    C:\Users\Public\pMatlab\MatlabMPI\examples\MatMPI>icacls Dos_Commands.WORKER2.1.sh
    Dos_Commands.WORKER2.1.sh Everyone:(F)
                              BUILTIN\Users:(I)(M)
                              Everyone:(I)(F)
                              NT AUTHORITY\SYSTEM:(I)(F)
                              NT AUTHORITY\BATCH:(I)(F)
                              BUILTIN\Administrators:(I)(F)
                              NT AUTHORITY\INTERACTIVE:(I)(F)
                              NT AUTHORITY\SERVICE:(I)(F)
                              WORKER1\root:(I)(F)
    Running the file locally works fine. Running the file from the Windows GUI on WORKER2 works fine. If I ssh from WORKER2 to itself, the file works fine. If I connect via Remote Desktop from WORKER1 to WORKER2 and run the file it works fine. The only time I get a permission denied error is if I ssh from WORKER1 to WORKER2 and then try to run the file on WORKER1 from there (which unfortunately is the only thing I care to do).

    From what I can see, I have the maximum possible permission set for file sharing in Windows, and WORKER1 and WORKER2 are on the same LAN (marked as the Home network) and in the same Homegroup. The sshd on WORKER2 is installed as a service. I apologize if this is a really basic question - I am very new to this stuff and tried searching but have been unable to find anything. Here is a screenshot of my settings in the Network and Sharing Center. Thanks!
    Attached Thumbnails Attached Thumbnails file sharing permission issue involving ssh, cygwin-security.jpg  
    Last edited by turb; 01 Feb 2012 at 14:27. Reason: added picture
      My Computer


  2. Posts : 2
    Windows 7 Enterprise 64 bit
    Thread Starter
       #2

    Issue resolved. It turns out that all of my permissions were set fine, but the software I was using (pMatlab) unzips as an encrypted folder! I did not know that green folder meant encrypted - I just thought that maybe you could set folder colors and the author liked to color-code his folders.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 17:55.
Find Us