-   Linux - Software (
-   -   How can create a directory on Windows machine from Linux? (

Felipe 12-10-2012 03:26 AM

How can create a directory on Windows machine from Linux?

I'm trying to create a remote directory on a share of Windows from a Linux console (Windows computers don't have installed service ftp).

Can any tell me how can it be done?

Windows computers are joined to Active Directory but not Linux machines.
- From windows console I can create it with:

mkdir \\server\share\directory
- From Linux console I can create it with smbclient if Linux computer is joined to Active Directory:

smbclient -U 'DOMAIN/user%pass' -W DOMAIN -N -c '//server/share/dir'
But my Linux machine is not joined to Active Directory and smbclient doesn't work.

Any suggestion about how to create the directory on the share of windows machine from linux console?


smallpond 12-10-2012 03:26 PM

How are you authenticating? Winbind?

What error do you get from mkdir?

Felipe 12-10-2012 03:50 PM


Finally, I've used a java program and jcifs (

Then I create the remote directory with:

new SmbFile("smb://DOMAIN;username:passwd@server/share/directory")).mkdir();
Of course, the user "username" has rights to create the "directory" on the "share" of "server"


All times are GMT -5. The time now is 04:10 AM.