Please see also Weird case of "Administrator Privileges" at boot time.
A 355KB DOC is available at www.chrisgreaves.com/Downloads/Win10Ass ... Folder.doc. This post text is at the foot of the document("Thursday, February 11, 2021")
How can I make "Permissions" stick on a shared drive on a Win10 laptop?
I am driven crazy trying to resolve an issue I first raised back in 2010. I tried then and have tried since to rid myself of SUBST.
Yesterday I managed to name my laptop computer "AT" and produced a share "T" which is my data drive T: (a Veracrypt decrypted partition)
I have a batch file ( NetUse.bat attached) which works once T is given permissions. The Batchfile is called repeatedly from my autoexec.bat.
The problem as I see it is that my boot-time batch file works only after I have manually intervened to reset permissions on the shared T which is assigned to T: which is my Veracrypt partition (after decryption)
The image above shows my manipulation to check ON full permission on the share "T" to Everyone. Yes, Everyone is risky, but until I can get this to work I'll be lenient.
Once the permissions are re-issued manually at reboot time, the batch file runs quite happily. In the image above I have made three fake drives S:, V:, and W: that save me time by giving me speedy access to lengthy folder trees.
I am not only confounded by the hurdles imposed by MSWindows, but eternally grateful for any pointers that show me "what I am doing wrong".
Thanks
Chris
make "Permissions" stick on a shared drive on a Win10 laptop
-
- PlutoniumLounger
- Posts: 15615
- Joined: 24 Jan 2010, 23:23
- Location: brings.slot.perky
make "Permissions" stick on a shared drive on a Win10 laptop
You do not have the required permissions to view the files attached to this post.
Last edited by ChrisGreaves on 21 Feb 2021, 22:39, edited 1 time in total.
There's nothing heavier than an empty water bottle
-
- Administrator
- Posts: 12604
- Joined: 16 Jan 2010, 15:49
- Location: London, Europe
Re: make "Permissions" stick on a shared drive on a Win10 laptop
How are you sharing T
You could try using a line like this in your BAT file
(where sharename is the name you gave the share)
You could try using a line like this in your BAT file
Code: Select all
NET SHARE Sharename=T: /GRANT:Everyone,FULL
StuartR
-
- PlutoniumLounger
- Posts: 15615
- Joined: 24 Jan 2010, 23:23
- Location: brings.slot.perky
Re: make "Permissions" stick on a shared drive on a Win10 laptop
A 666KB DOC is available at http://www.chrisgreaves.com/Downloads/Win10AssignDriveLetterToFolder.doc. This post text is at the foot of the document("Friday, February 12, 2021")
I have a working reboot system, although it needs a good haircut.
(1) In "C:\Users\Chris074\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup" I have a file "AutoSimple.bat"
Code: Select all
set pause=pause
echo This is %0 running
%pause%
start "" "C:\Users\Chris074\AppData\Roaming\Microsoft\Windows\Start Menu\AutoExec.bat - Shortcut.lnk"
%pause%
(3) The file "AutoExec.bat" is a stripped-down version of my normal all-singing all-dancing AutoEexc.bat file.
Code: Select all
:: AutoExec.bat held in C:\Users\Chris074\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup
set pause=pause
:: Mount the encrypted drive
if not exist T: "C:\Program Files\VeraCrypt\VeraCrypt.exe" /q /l T /v \Device\Harddisk1\Partition4
%pause%
:: Grant Permissions to the share "T" https://eileenslounge.com/viewtopic.php?p=280748&sid=bb31f06354b6050842d267f1b98c7826#p280748
NET SHARE T=T: /GRANT:Everyone,FULL
%pause%
timeout /T 5
%pause%
:: Mount a shortcut drive "S:" where "S"==="Stain" (application folder)
net use S: /DELETE
%pause%
net use S: \\AT\T\Greaves\Products\USER\Stain /PERSISTENT:YES
%pause%
(5) A subsequent run of my Fakes.bat (attached) makes all four drives (S:, U:, V: and W:) appear in Explorer.
Thanks to Stuart for getting me over this hurdle and to the Finish Line!
Chris
You do not have the required permissions to view the files attached to this post.
There's nothing heavier than an empty water bottle
-
- Administrator
- Posts: 12604
- Joined: 16 Jan 2010, 15:49
- Location: London, Europe