New Question

copyimage script not working

asked 2014-11-28 05:16:51 +0300

opswatch gravatar image

updated 2014-11-28 15:45:33 +0300

alexpilotti gravatar image

Hi I have built a maas vm and everything is setup properly except when I run the copyimage script nothing happens and I get not errors, im able to access the samba share from windows and I have ran the copy-item command on a test file and it copies the file I can see it on windows but from the Linux vm im not able to, any ideas?

Using windows 8.1

edit retag flag offensive close merge delete


Just to clear things up. The samba share is mounted on windows and you can see it when doing a: net use You can copy over a file form windows, but it does not appear to be on the target.Is this correct? If so, lets make sure that copying files over is possible. You may need to set up a samba user.

gabriel-samfira gravatar imagegabriel-samfira ( 2014-11-28 14:04:50 +0300 )edit

1 answer

Sort by » oldest newest most voted

answered 2014-11-28 14:22:42 +0300

gabriel-samfira gravatar image

Lets get some more info on the situation first.

Please add the output of the following commands:

On the windows machine you ran the script on:

net use

If the MaaS samba share is not there, lets try to add it and copy over some files again:

# The samba share on the MaaS server should be named reminst
New-SmbMapping -RemotePath \\<MAAS IP>\reminst -LocalPath X:

you should now be able to see a new drive letter called X. Lets try to write something there:

echo testing > X:\test.txt

NOTE: it is not necessary to add a SMB mapping for this to work. UNC path names should be enough. We do this for debug purposes only.

On your MaaS VM:

Lets see if the file is on the MaaS node:

ls /var/lib/maas/samba

You should see a test.txt. If the file is there, you should be able to copy over the WinPE files using:

CopyImageToMaaS.ps1 -TargetPath X:\

Please take note, that MaaS expects one of the following folder names to be present in /var/lib/maas/samba:


Also, if you have not already done so, please read the guide at:

edit flag offensive delete link more


The results of the net use command were New connections will be remembered There are no entries on the list The test file worked There was no win2012hvr2 folder in /var/lib/maas/samba so I created it and I can see both that and the test file on windows and the maas vm but the copyimagetomaas is still not doing anything no errors either As a test I copied the .wim file into the samba folder with no problems, I can see it on both sides, When I ran the create image script the file it outputted for the wim was Hyper-V Server 2012 R2 SERVERHYPERCORE.wim I believe its correct, from taking a look at the copy image script it does not seem to be creating any of the new folders either, any ideas?

opswatch gravatar imageopswatch ( 2014-11-29 06:19:06 +0300 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2014-11-28 05:16:51 +0300

Seen: 385 times

Last updated: Nov 28 '14