Hi, Thanks for the information. I have to update perl script for "I" drive mapping. &resetDriveMapping( "I:", $diskArchive ) ; I have to change perl script I map from "\\store\project" to \\store\projectnew$. The new share is hidden format($). I used following function to test the mapping. thank you. smw11
sub resetDriveMapping { my $isDriveLetter = shift ; my $isSharename = shift ; my $Ifiletest = "$isDriveLetter\\idriveTESTfrom" . $ENV{COMPUTERNA +ME} . ".txt" ; my $Itestmsg = "...resetting: \'$isDriveLetter\' drive mapping fro +m \'$ENV{COMPUTERNAME}\' to \'$isSharename\'" ; &writeLogFile($Itestmsg); my $runCommand = "echo Y|net use $isDriveLetter /DELETE" ; my $retvalue = system($runCommand); if ($retvalue) { &writeLogFile("cannot delete drive $isDriveLetter"); } $runCommand = "net use $isDriveLetter $isSharename" ; $retvalue = system($runCommand); if ($retvalue) { &writeLogFile("cannot map drive $isDriveLetter to $isSharename +"); } #test share mapping $Itestmsg = "...start testing: \'$isDriveLetter\' drive mapping fr +om \'$ENV{COMPUTERNAME}\' to \'$isSharename\'" ; &writeLogFile($Itestmsg); open(ITEST, ">$Ifiletest" ) || &writeLogFile("cannot CREATE $Ifile +test") ; print ITEST "$Itestmsg\n" ; close(ITEST) ; if ( ! -e "$Ifiletest" ) { &writeLogFile("EXITing: test file does not exist \'$Ifiletest\ +'"); exit(0) ; } open(ITEST, "$Ifiletest" ) || &writeLogFile("cannot OPEN $Ifiletes +t") ; my $Itestbuf = "" ; while (<ITEST>) { $Itestbuf = $_ ; } close(ITEST) ; unless ( $Itestbuf ) { &writeLogFile("EXITing: could *not* read test content \'$Ifile +test\'"); exit(0) ; } else { unlink( $Ifiletest ) || &writeLogFile("could not DELETE $Ifile +test") ; &writeLogFile("...end testing: \'$isDriveLetter\' drive mappin +g COMPLETED successfully") ; } }

In reply to Re^2: How to access Storage hidden share by smw11
in thread How to access Storage hidden share by smw11

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.