TS setup for multiple users

  • Thread starter Thread starter Markus
  • Start date Start date
M

Markus

Guest
I am a newbie to TS, but am excited about running my app (normally installed
on LANs) over a WAN using TS and possibly over the Internet.

I have a client with 3000 employees in 1000 departments. But they only need
max of 10 concurrent users to use my app over their WAN.

One basic question I have concerns TS setup. My app writes temp files to
the same folder in which the EXE resides. I understand I must be sure each
user runs this EXE from their own user folder under TS to avoid user temp
file conflicts which is not needed when the app runs on a workstation in a
LAN.

This means I need a minimum of 10 folders for 10 users on the server, and 10
copies of my EXE running in each folder.

If that is true, here’s where I get confused. I have the potential of 3000
users wanting to log in to the server under one of 10 logins. If I set up
generic logins like USER1, USER2, etc. for logging in to the server, how does
TS handle the possibility of two people choosing to login as USER1 at the
same time? If TS allows this, then temporary files created by my EXE for
these 2 users would overwrite each other since they would both be using the
same user folder and same EXE.

If TS allows this, then can I assume I must instead have 3000 logins to the
server for every staff, and ergo 3000 folders and 3000 copies of my EXE?
Seems like there must be a better way.

Appreciate your patience with my novice question, and hope you can help.

Mark
 
Re: TS setup for multiple users

Hi Mark,

You need to modify your application so that it writes to
the current user's temp folder instead. This is accomplished
by calling GetTempPath (or read the environment variable):

GetTempPath Function

http://msdn2.microsoft.com/en-us/library/aa364992.aspx

Your current method is not optimal even for a LAN
environment. Temporary files should be stored in the
temp folder and *not* in the program folder. In most cases
users should be able to run an application with only read
and execute access to the program folder.

Please take a look at the XP logo specifications document,
there is good information on some aspects of app design:

Designed for Windows XP Application Specification

http://www.microsoft.com/downloads/details.aspx?FamilyID=209e3d65-f0be-4eef-8602-73bb9bc29d54

Are you going to be hosting your application on your server
and then allowing your client to run it for a monthly fee
over the Internet? If yes then a different licensing program
applies and this would change the answer I gave you in
your other post in regards to licensing requirements.

Thanks.

-TP

Markus wrote:
> I am a newbie to TS, but am excited about running my app (normally
> installed on LANs) over a WAN using TS and possibly over the Internet.
>
> I have a client with 3000 employees in 1000 departments. But they
> only need max of 10 concurrent users to use my app over their WAN.
>
> One basic question I have concerns TS setup. My app writes temp
> files to the same folder in which the EXE resides. I understand I
> must be sure each user runs this EXE from their own user folder under
> TS to avoid user temp file conflicts which is not needed when the app
> runs on a workstation in a LAN.
>
> This means I need a minimum of 10 folders for 10 users on the server,
> and 10 copies of my EXE running in each folder.
>
> If that is true, here’s where I get confused. I have the potential
> of 3000 users wanting to log in to the server under one of 10 logins.
> If I set up generic logins like USER1, USER2, etc. for logging in to
> the server, how does TS handle the possibility of two people choosing
> to login as USER1 at the same time? If TS allows this, then
> temporary files created by my EXE for these 2 users would overwrite
> each other since they would both be using the same user folder and
> same EXE.
>
> If TS allows this, then can I assume I must instead have 3000 logins
> to the server for every staff, and ergo 3000 folders and 3000 copies
> of my EXE? Seems like there must be a better way.
>
> Appreciate your patience with my novice question, and hope you can
> help.
>
> Mark
 
Re: TS setup for multiple users

Your own analysis of the requirements show that this is not a
realistic setup.
All users should have their own personal user account (to avoid
profile corruption, irratic switching of printers, etc), and all
users should run an instance of the same application's exe file
(for memory sharing).
But: user-specific files, like the temporary file you mention,
should be placed in a user-specific folder. If the application uses
standard Windows programming techniques, the TS installation
procedure (using "install mode") will make sure that such a folder
is created and that the application is redirected to it.
But if you have hardcoded the path to the temporary file as the
application folder, then this wil not work, and your application is
not suitable to run in a multi-user environment.

Recommended reading:

Terminal Services Programming Guidelines
http://msdn2.microsoft.com/en-us/library/aa383490.aspx

186498 - Terminal Server Application Integration Information
http://support.microsoft.com/?kbid=186498
_________________________________________________________
Vera Noest
MCSE, CCEA, Microsoft MVP - Terminal Server
TS troubleshooting: http://ts.veranoest.net
___ please respond in newsgroup, NOT by private email ___

=?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote on
12 dec 2007 in microsoft.public.windows.terminal_services:

> I am a newbie to TS, but am excited about running my app
> (normally installed on LANs) over a WAN using TS and possibly
> over the Internet.
>
> I have a client with 3000 employees in 1000 departments. But
> they only need max of 10 concurrent users to use my app over
> their WAN.
>
> One basic question I have concerns TS setup. My app writes temp
> files to the same folder in which the EXE resides. I understand
> I must be sure each user runs this EXE from their own user
> folder under TS to avoid user temp file conflicts which is not
> needed when the app runs on a workstation in a LAN.
>
> This means I need a minimum of 10 folders for 10 users on the
> server, and 10 copies of my EXE running in each folder.
>
> If that is true, here’s where I get confused. I have the
> potential of 3000 users wanting to log in to the server under
> one of 10 logins. If I set up generic logins like USER1, USER2,
> etc. for logging in to the server, how does TS handle the
> possibility of two people choosing to login as USER1 at the same
> time? If TS allows this, then temporary files created by my EXE
> for these 2 users would overwrite each other since they would
> both be using the same user folder and same EXE.
>
> If TS allows this, then can I assume I must instead have 3000
> logins to the server for every staff, and ergo 3000 folders and
> 3000 copies of my EXE? Seems like there must be a better way.
>
> Appreciate your patience with my novice question, and hope you
> can help.
>
> Mark
 
Re: TS setup for multiple users

TP,

Actually, my app allows users to specify a temp folder to use for any files
created by my code. Problem is the runtime I use creates temp files
(uisually temporary SQL files), and they are created in the same folder as
the EXE. I am looking into a way to reconfig the runtime to write to a
different folder, tho.

No, this is not a monthly fee app. My clients license it and run it on
their own equipment. I had hoped to allow them to access it thru their
Intranet using TS, as well as over their WAN using TS. But it sounds like
the licensing fees would not be justified given the small # of users that
need access. Will have to figure a different way, or write up a web app
comonent for this function.

Thanks,
Mark

"TP" wrote:

> Hi Mark,
>
> You need to modify your application so that it writes to
> the current user's temp folder instead. This is accomplished
> by calling GetTempPath (or read the environment variable):
>
> GetTempPath Function
>
> http://msdn2.microsoft.com/en-us/library/aa364992.aspx
>
> Your current method is not optimal even for a LAN
> environment. Temporary files should be stored in the
> temp folder and *not* in the program folder. In most cases
> users should be able to run an application with only read
> and execute access to the program folder.
>
> Please take a look at the XP logo specifications document,
> there is good information on some aspects of app design:
>
> Designed for Windows XP Application Specification
>
> http://www.microsoft.com/downloads/details.aspx?FamilyID=209e3d65-f0be-4eef-8602-73bb9bc29d54
>
> Are you going to be hosting your application on your server
> and then allowing your client to run it for a monthly fee
> over the Internet? If yes then a different licensing program
> applies and this would change the answer I gave you in
> your other post in regards to licensing requirements.
>
> Thanks.
>
> -TP
>
> Markus wrote:
> > I am a newbie to TS, but am excited about running my app (normally
> > installed on LANs) over a WAN using TS and possibly over the Internet.
> >
> > I have a client with 3000 employees in 1000 departments. But they
> > only need max of 10 concurrent users to use my app over their WAN.
> >
> > One basic question I have concerns TS setup. My app writes temp
> > files to the same folder in which the EXE resides. I understand I
> > must be sure each user runs this EXE from their own user folder under
> > TS to avoid user temp file conflicts which is not needed when the app
> > runs on a workstation in a LAN.
> >
> > This means I need a minimum of 10 folders for 10 users on the server,
> > and 10 copies of my EXE running in each folder.
> >
> > If that is true, here’s where I get confused. I have the potential
> > of 3000 users wanting to log in to the server under one of 10 logins.
> > If I set up generic logins like USER1, USER2, etc. for logging in to
> > the server, how does TS handle the possibility of two people choosing
> > to login as USER1 at the same time? If TS allows this, then
> > temporary files created by my EXE for these 2 users would overwrite
> > each other since they would both be using the same user folder and
> > same EXE.
> >
> > If TS allows this, then can I assume I must instead have 3000 logins
> > to the server for every staff, and ergo 3000 folders and 3000 copies
> > of my EXE? Seems like there must be a better way.
> >
> > Appreciate your patience with my novice question, and hope you can
> > help.
> >
> > Mark

>
>
 
Re: TS setup for multiple users

Vera,

I think I see. As posted to TP, any temp files created by my app are done
in a user specified temp folder (tho for TS, I will probably use gettemp as
TP suggested rather than giving users or admin control over where these will
be written). So the problem is with the runtime I use, which creates temp
files in the folder where the EXE is located.

One very important thing I want to be sure I understand. When running an
app under TS, should each user be running a separate copy of my EXE stored in
their user folder, or should they all run the same EXE file stored in a
common folder?

I appreciate your patience and assistance,
Mark





"Vera Noest [MVP]" wrote:

> Your own analysis of the requirements show that this is not a
> realistic setup.
> All users should have their own personal user account (to avoid
> profile corruption, irratic switching of printers, etc), and all
> users should run an instance of the same application's exe file
> (for memory sharing).
> But: user-specific files, like the temporary file you mention,
> should be placed in a user-specific folder. If the application uses
> standard Windows programming techniques, the TS installation
> procedure (using "install mode") will make sure that such a folder
> is created and that the application is redirected to it.
> But if you have hardcoded the path to the temporary file as the
> application folder, then this wil not work, and your application is
> not suitable to run in a multi-user environment.
>
> Recommended reading:
>
> Terminal Services Programming Guidelines
> http://msdn2.microsoft.com/en-us/library/aa383490.aspx
>
> 186498 - Terminal Server Application Integration Information
> http://support.microsoft.com/?kbid=186498
> _________________________________________________________
> Vera Noest
> MCSE, CCEA, Microsoft MVP - Terminal Server
> TS troubleshooting: http://ts.veranoest.net
> ___ please respond in newsgroup, NOT by private email ___
>
> =?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote on
> 12 dec 2007 in microsoft.public.windows.terminal_services:
>
> > I am a newbie to TS, but am excited about running my app
> > (normally installed on LANs) over a WAN using TS and possibly
> > over the Internet.
> >
> > I have a client with 3000 employees in 1000 departments. But
> > they only need max of 10 concurrent users to use my app over
> > their WAN.
> >
> > One basic question I have concerns TS setup. My app writes temp
> > files to the same folder in which the EXE resides. I understand
> > I must be sure each user runs this EXE from their own user
> > folder under TS to avoid user temp file conflicts which is not
> > needed when the app runs on a workstation in a LAN.
> >
> > This means I need a minimum of 10 folders for 10 users on the
> > server, and 10 copies of my EXE running in each folder.
> >
> > If that is true, here’s where I get confused. I have the
> > potential of 3000 users wanting to log in to the server under
> > one of 10 logins. If I set up generic logins like USER1, USER2,
> > etc. for logging in to the server, how does TS handle the
> > possibility of two people choosing to login as USER1 at the same
> > time? If TS allows this, then temporary files created by my EXE
> > for these 2 users would overwrite each other since they would
> > both be using the same user folder and same EXE.
> >
> > If TS allows this, then can I assume I must instead have 3000
> > logins to the server for every staff, and ergo 3000 folders and
> > 3000 copies of my EXE? Seems like there must be a better way.
> >
> > Appreciate your patience with my novice question, and hope you
> > can help.
> >
> > Mark

>
 
Re: TS setup for multiple users

All users run the same .exe file. You install the application only
once, while the server is in *install mode*. Read in the KB article
I mentioned about install mode, this is vital to make sure that
user's preferences are kept separate from each other.

_________________________________________________________
Vera Noest
MCSE, CCEA, Microsoft MVP - Terminal Server
TS troubleshooting: http://ts.veranoest.net
*----------- Please reply in newsgroup -------------*

=?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote on
13 dec 2007:

> Vera,
>
> I think I see. As posted to TP, any temp files created by my
> app are done in a user specified temp folder (tho for TS, I will
> probably use gettemp as TP suggested rather than giving users or
> admin control over where these will be written). So the problem
> is with the runtime I use, which creates temp files in the
> folder where the EXE is located.
>
> One very important thing I want to be sure I understand. When
> running an app under TS, should each user be running a separate
> copy of my EXE stored in their user folder, or should they all
> run the same EXE file stored in a common folder?
>
> I appreciate your patience and assistance,
> Mark
>
>
>
>
>
> "Vera Noest [MVP]" wrote:
>
>> Your own analysis of the requirements show that this is not a
>> realistic setup.
>> All users should have their own personal user account (to avoid
>> profile corruption, irratic switching of printers, etc), and
>> all users should run an instance of the same application's exe
>> file (for memory sharing).
>> But: user-specific files, like the temporary file you mention,
>> should be placed in a user-specific folder. If the application
>> uses standard Windows programming techniques, the TS
>> installation procedure (using "install mode") will make sure
>> that such a folder is created and that the application is
>> redirected to it. But if you have hardcoded the path to the
>> temporary file as the application folder, then this wil not
>> work, and your application is not suitable to run in a
>> multi-user environment.
>>
>> Recommended reading:
>>
>> Terminal Services Programming Guidelines
>> http://msdn2.microsoft.com/en-us/library/aa383490.aspx
>>
>> 186498 - Terminal Server Application Integration Information
>> http://support.microsoft.com/?kbid=186498
>> _________________________________________________________
>> Vera Noest
>> MCSE, CCEA, Microsoft MVP - Terminal Server
>> TS troubleshooting: http://ts.veranoest.net
>> ___ please respond in newsgroup, NOT by private email ___
>>
>> =?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote
>> on 12 dec 2007 in microsoft.public.windows.terminal_services:
>>
>> > I am a newbie to TS, but am excited about running my app
>> > (normally installed on LANs) over a WAN using TS and possibly
>> > over the Internet.
>> >
>> > I have a client with 3000 employees in 1000 departments. But
>> > they only need max of 10 concurrent users to use my app over
>> > their WAN.
>> >
>> > One basic question I have concerns TS setup. My app writes
>> > temp files to the same folder in which the EXE resides. I
>> > understand I must be sure each user runs this EXE from their
>> > own user folder under TS to avoid user temp file conflicts
>> > which is not needed when the app runs on a workstation in a
>> > LAN.
>> >
>> > This means I need a minimum of 10 folders for 10 users on the
>> > server, and 10 copies of my EXE running in each folder.
>> >
>> > If that is true, here’s where I get confused. I have
>> > the potential of 3000 users wanting to log in to the server
>> > under one of 10 logins. If I set up generic logins like
>> > USER1, USER2, etc. for logging in to the server, how does TS
>> > handle the possibility of two people choosing to login as
>> > USER1 at the same time? If TS allows this, then temporary
>> > files created by my EXE for these 2 users would overwrite
>> > each other since they would both be using the same user
>> > folder and same EXE.
>> >
>> > If TS allows this, then can I assume I must instead have 3000
>> > logins to the server for every staff, and ergo 3000 folders
>> > and 3000 copies of my EXE? Seems like there must be a better
>> > way.
>> >
>> > Appreciate your patience with my novice question, and hope
>> > you can help.
>> >
>> > Mark
 
Re: TS setup for multiple users

Thanks Vera, will do some reading on it.
Mark


"Vera Noest [MVP]" wrote:

> All users run the same .exe file. You install the application only
> once, while the server is in *install mode*. Read in the KB article
> I mentioned about install mode, this is vital to make sure that
> user's preferences are kept separate from each other.
>
> _________________________________________________________
> Vera Noest
> MCSE, CCEA, Microsoft MVP - Terminal Server
> TS troubleshooting: http://ts.veranoest.net
> *----------- Please reply in newsgroup -------------*
>
> =?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote on
> 13 dec 2007:
>
> > Vera,
> >
> > I think I see. As posted to TP, any temp files created by my
> > app are done in a user specified temp folder (tho for TS, I will
> > probably use gettemp as TP suggested rather than giving users or
> > admin control over where these will be written). So the problem
> > is with the runtime I use, which creates temp files in the
> > folder where the EXE is located.
> >
> > One very important thing I want to be sure I understand. When
> > running an app under TS, should each user be running a separate
> > copy of my EXE stored in their user folder, or should they all
> > run the same EXE file stored in a common folder?
> >
> > I appreciate your patience and assistance,
> > Mark
> >
> >
> >
> >
> >
> > "Vera Noest [MVP]" wrote:
> >
> >> Your own analysis of the requirements show that this is not a
> >> realistic setup.
> >> All users should have their own personal user account (to avoid
> >> profile corruption, irratic switching of printers, etc), and
> >> all users should run an instance of the same application's exe
> >> file (for memory sharing).
> >> But: user-specific files, like the temporary file you mention,
> >> should be placed in a user-specific folder. If the application
> >> uses standard Windows programming techniques, the TS
> >> installation procedure (using "install mode") will make sure
> >> that such a folder is created and that the application is
> >> redirected to it. But if you have hardcoded the path to the
> >> temporary file as the application folder, then this wil not
> >> work, and your application is not suitable to run in a
> >> multi-user environment.
> >>
> >> Recommended reading:
> >>
> >> Terminal Services Programming Guidelines
> >> http://msdn2.microsoft.com/en-us/library/aa383490.aspx
> >>
> >> 186498 - Terminal Server Application Integration Information
> >> http://support.microsoft.com/?kbid=186498
> >> _________________________________________________________
> >> Vera Noest
> >> MCSE, CCEA, Microsoft MVP - Terminal Server
> >> TS troubleshooting: http://ts.veranoest.net
> >> ___ please respond in newsgroup, NOT by private email ___
> >>
> >> =?Utf-8?B?TWFya3Vz?= <Markus@discussions.microsoft.com> wrote
> >> on 12 dec 2007 in microsoft.public.windows.terminal_services:
> >>
> >> > I am a newbie to TS, but am excited about running my app
> >> > (normally installed on LANs) over a WAN using TS and possibly
> >> > over the Internet.
> >> >
> >> > I have a client with 3000 employees in 1000 departments. But
> >> > they only need max of 10 concurrent users to use my app over
> >> > their WAN.
> >> >
> >> > One basic question I have concerns TS setup. My app writes
> >> > temp files to the same folder in which the EXE resides. I
> >> > understand I must be sure each user runs this EXE from their
> >> > own user folder under TS to avoid user temp file conflicts
> >> > which is not needed when the app runs on a workstation in a
> >> > LAN.
> >> >
> >> > This means I need a minimum of 10 folders for 10 users on the
> >> > server, and 10 copies of my EXE running in each folder.
> >> >
> >> > If that is true, here’s where I get confused. I have
> >> > the potential of 3000 users wanting to log in to the server
> >> > under one of 10 logins. If I set up generic logins like
> >> > USER1, USER2, etc. for logging in to the server, how does TS
> >> > handle the possibility of two people choosing to login as
> >> > USER1 at the same time? If TS allows this, then temporary
> >> > files created by my EXE for these 2 users would overwrite
> >> > each other since they would both be using the same user
> >> > folder and same EXE.
> >> >
> >> > If TS allows this, then can I assume I must instead have 3000
> >> > logins to the server for every staff, and ergo 3000 folders
> >> > and 3000 copies of my EXE? Seems like there must be a better
> >> > way.
> >> >
> >> > Appreciate your patience with my novice question, and hope
> >> > you can help.
> >> >
> >> > Mark

>
 
Back
Top