Link to home
Start Free TrialLog in
Avatar of jnordeng
jnordeng

asked on

Can't get UNC Directory to show up in Windows Explorer via Published App

I know this is a simple task, but Having some issues.  I have a XenApp 6.5 farm.  I want to launch Windows Explorer to a specific UNC.  I have used batch scripting to map a drive and launch Explorer.  I have tried just publishing the directory using Content.  However; all tests work local on the box, but when I test via published app, it never goes to the network location, just the local drive.  

Can someone please help.  As I'm going insane here.

Thanks in advance.

Here's a sample of what's in the batch script
net use u: /delete
rem net use u: /delete /y
net use u: \\server.domain.local\test
%windir%\explorer.exe u:
Avatar of SoHandy
SoHandy
Flag of Ireland image

just reread your question, think i misread, above mightened be your solution
Avatar of jnordeng
jnordeng

ASKER

Thanks, appreciate the help.  My issue is trying to published the mapped drive to show up in Windows Explorer. I'm doing this via a published application in a Citrix (XenApp 6.5) environment running on Windows 2008 R2.  We need to restrict to this directory (aside from permissions) to trying to get it to open here.

Thanks
Any other thoughts or recommendations?
no experience of the system youre using there man sorry
Avatar of Dirk Kotte
i think explorer don't work for you (as published app)
try internet-explorer instead ...

path: %ProgramFiles(x86)%\Internet Explorer\iexplore.exe
Argument: u:
Thanks Dirk, I'll give that a try.  I just wanted to confirm, you are suggested in the published app pass path: %ProgramFiles(x86)%\Internet Explorer\iexplore.exe as the published app and then u?  Where do I map U?  Or are you suggesting this would be part of the bat script?  I did try with Internet Explorer initially, but had the same behavior where it would launch but not go to the file location.

Thanks in advance.
I've adjusted my script to the following - various forms.  But need to add in something for user creds - this works local on the box, but fails when trying to launch via Citrix Published app.

if "%userdomain%" == "Domain" if not exist u:\ net use u: "\\server.domain.local\filelocation"  /USER:domain\%username% /PERSISTENT:YES >NUL

start "%ProgramFiles(x86)%\Internet Explorer\iexplore.exe" "\\server.domain.local\filelocation"

Any other thoughts?

Thanks
mappeddrive.png
we map drives from GPO (or VBS base logon script) while/before starting the app.
why do you need to specify the username? Isn't the user a member of your domain?  
Mapping a drive take the credentials from authenticated user.

after mapping drive u: ... why do you use the UNC path within next command? (...plore.exe" "\\server.domain.local\filelocation")
Thanks for the response Dirk.  We have multiple domains.  The main domain, we'll call domain1,  user is logged in but the Citrix servers reside in another domain we'll call domain 2.  So Domain 2 has the groups that are tied to the published apps, domain 1 user  is nested into these groups.

Should Add, I tried without the if not user exist line, but get access denied.  I know the user has permissions as it can be done via the command line/run line on the Citrix server itself, but fails when executing the Publsihed App with Access Denied.


I'll try again.

Thanks
ok, users are from Domain1 - connects to citrix at Domain2 and should use files from domain1 (U:) ... correct?

if the script correctly maps drive u: , you should use u: within citrix apps too. because the credentials specified are for the mapping and not for UNC-access later.

if IE opens, you are able to save the page to the U: drive? is it mapped now?

If not , publish cmd.exe and try the steps used by your script here.
Thanks Dirk, actually the files they need are on domain 2.  So I'll try to make this more visual


User logs into carsdomain.local\user account to Web Interface within Citrix.  Based on their permissions in truckrus.local where their carsdomain.local user is nested in a trucksrus.local security group, they will launch a published app which will launch this script (when it's working), and then present them with a mapped drive to trucksrus.local from a Citrix Server.  This carsdomain.local user is nested in the trucksrus.local domain.

Does that help?


I'll go back to command prompt where I started.  The main issue here is getting the script to pass the user creds to map the drive.

Thanks
Was thinking more on this, not sure what script method is best, but since this has to run on a Citrix box to have firewall access to the share, the domain account needs to be the same domain, so per the example that would be trucksrus.local.  SO was thinking perhaps using a service account to run the script is better as the users would have permission via the published app.  I would have to encrypt or hash the password fora  service account, so will need to adjust the script to map the drive using the service account and open via windows explorer.

Any more thoughts to accomplish this is appreciated.
ASKER CERTIFIED SOLUTION
Avatar of jnordeng
jnordeng

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial