in reply to Identifying Windows file share names
I doubt i understood your question: if so try to explain your needs in a more accurate way.
From what I understand you connect to a server share, let's say \\10.10.10.10\share_name rigth? Now you want to know this share what path holds on the target server? Like c:\stuff\shared
If my assumptions are correct you can wrap some perl code around wmic /node:10.10.10.10 share get name,path command.
Like:
my $remote = '10.10.10.10'; my $share = 'share_name'; # connect to the share.. ... # get info on the share from remote system open my $cmd, "wmic /node:$remote share get name,path|" or die; while (<$cmd>){ chomp; my ($got_name, $got_path) = split /\s+/, $_; if ($got_name eq $share){ print "share [$share] at $ip is remotely: $got_path\n" } }
L*
|
|---|