R
RussR
Slobodan
Yes the batch script works if I manually execute it. It also works if I set
it as Run instead of RunOnce. It seems to only execute in FBA that too way
before the network is installed, at least according to FBA.log.
I'm going to put a Pause statement to see if it executes anywhere else. I'm
unsure how FBA will respond to this Pause statement.
What I'm probably going to do is use the Run key instead and call my batch
script to do whatever I need to do and then add the end of the batch script,
delete the Run key from the registry. How does that sound? Either that or
I could try FBA generic command with phase 8499 as you suggested.
RussR
Yes the batch script works if I manually execute it. It also works if I set
it as Run instead of RunOnce. It seems to only execute in FBA that too way
before the network is installed, at least according to FBA.log.
I'm going to put a Pause statement to see if it executes anywhere else. I'm
unsure how FBA will respond to this Pause statement.
What I'm probably going to do is use the Run key instead and call my batch
script to do whatever I need to do and then add the end of the batch script,
delete the Run key from the registry. How does that sound? Either that or
I could try FBA generic command with phase 8499 as you suggested.
RussR
Slobodan Brcin said:Your filter search should reveal "Misc. Command Line Tools".
If not then check your Visibility settings.
One probably stupid question, but I don't know what else could be the
problem:
Have you tried to run your bat file on your XPe image manually from command
line?
Does it work?
Also you can put "pause" in your bat file just to see if (and when) it is
called.
The fastest way (that I know) to deploy is to have direct 1000MBPS network
connection.
Development device with minimum of 1 GB RAM, so you wont need to close TD,
and whole DB should be cached in memory.
Target device:
1. Dual boot
2. One OS capable of sharing root of some partition.
The faster device the better.
TD output for build should be set directly on network share of target
device.
So build and deploy is very fast, and you don't need to close your
development machine.
You can continue to work, while FBA is in progress. Little human
multitasking
Regards,
Slobodan
willRussR said:usefulCall time of all three Run types is documented and it is not very
forIf you look at the MSDN docs, it says:your case.
[The RunOnce key is processed by FBA after Plug and Play device enumeration,
and again after DLL registration processing. It is then processed after
logon as the Run key. Typically, this flag is used when a reboot is required
(such as a DLL or OCX registration). ]
Just for the record, I had already read the docs on the RunOnce resource and
had posted specifically because my RunOnce Request seems to be executing in
FBA (though before FBA does network setup), but didn't seem to be executing
after logon as the Run key as it says above it should. So basically even
though it fails to execute at the right time in FBA, it should run after
first logon and thus set the shares, this doesn't happen. Why?
It's worth a shot to see if it works I guessRun might do the trick, but the cost is too great?
Come on man, you think I got this far w/o knowing how to use the FilterUse and learn to use Filter option in TD to search for components that
contain specific files.
Also you can copy manually reg.exe it has very low dependencies (almost
none).
option? I did search through it as well as the NG here, but there only seem
to be components for REGEDIT/registry editor. That's a bit bigger than the
simple REG.EXE command which is why I asked if you knew of a component
speficically for REG.EXE. I will try adding the REG.EXE as an extra file.
I am not even using my target device yet, I'm using my development machineBTW:
The best way is to have fast target computer for testing hardware unrelated
XPe configurations. This will allow you to build and deploy, and complete
FBA in less than 15 minutes.
So you can experiment with elementary settings and see how they behave.
It is much faster and more accurate to try it yourself, then to ask simple
questions.
and building and deploying images to an extra disk within my system and then
booting into that disk to load XPe. I wouldn't call this method fast, the
whole process of building the image, running fba and boot for the first time
is rather time consuming in general, but I don't think that there's a method
faster than this.
I really do appreciate your help Slobodan, but please don't assume that I'm
not searching the documentation and all to find answers even if seems that
way.
RussR
usefulSlobodan Brcin said:Come on read the manual,at least these things are documented.
Build order is irrelevant in most cases when some sort of installation or
PnP is involved that modifies registry.
Call time of all three Run types is documented and it is not very
foryour case.
Run might do the trick, but the cost is too great?
Use and learn to use Filter option in TD to search for components that
contain specific files.
Also you can copy manually reg.exe it has very low dependencies (almost
none).
BTW:
The best way is to have fast target computer for testing hardware unrelated
XPe configurations. This will allow you to build and deploy, and complete
FBA in less than 15 minutes.
So you can experiment with elementary settings and see how they behave.
It is much faster and more accurate to try it yourself, then to ask simple
questions.
Regards,
Slobodan
Slobodan,
Does setting the build order on RunOnce have any effect on when it is
called
during FBA?
I was thinking if RunOnce doesn't do the trick, maybe Run will right?
Also, what components do I need to include to have the reg.exe command?
Thanks,
RussR
Russell,
You have very little (no) control over phase when RunOnce callbebehavior,made.
FBA Generic Command in the other hand can be called at exact phase you
set.
You can make it to be called between before or after some other
components.
Is it the cleanest way?
Who knows, there always may be better way of doing some specific things.
If
you want to spend hours trying to figure it out.
You could event find the component that registers some dll that changes
this
registry value, and you could find some way to modify this
butrebootin
this case that would be pure waste of time.
Regards,
Slobodan
Slobodan, the info about phase 8499 being last phase before
iscallingvery
useful.
What is the advantage of doing it with FBA Generic Command as opposed
to
a
RunOnce request in the Extra Resources section?
Currently, I've created a bat file with all the things I need to get
done
(setting which folders get shared, etc) and I have put it in the
RunOnce
request under extra resources, however looking at fbalog.txt, it seems
to
get executed before the network is setup so my shares never get set.
I
thought of setting it as Run instead of RunOnce, but that is ugly.
Would setting it with FBA Generic Command with phase 8499, be the
cleanest
way of doing it?
Thanks,
Russr
Open Resources category:
And create FBA generic command that will call reg.exe with
appropriate
parameters at phase 8499 (last phase before first reboot).
You don't need to change build order since it has less significance
than
phase number.
Regards,
Slobodan
Slobodan, thanks for the responses!!! I put those registry keys
in
Extra
Settings like John suggested and as I said in my last post, it
seems
like
they get overwritten by something else in FBA. Build order
doesn't
seem
to
make a difference.
You suggested:
You can always call reg.exe at some higher FBA phase to change
registry
entries, not peaty but it is working.
How do I call reg.exe at some higher phase ensuring that other
stuff
doesn't
overwrite the keys I'm setting? The key question beingcan'tit
at
the
higher phase.
Thanks
Build order won't help you if something during FBA changes value
in
registry
during the some higher phase.
I don't have these registry keys in my XPe build so I
findfolderscomponent
that is overwriting your settings.
You can always call reg.exe at some higher FBA phase to change
registry
entries, not peaty but it is working.
Regards,
Slobodan
I ended up putting this registry hack in the Extra Registry
Settings
section
and I put a build order of 1001, but it didn't do that trick.
What
build
order do you think I need to get this to not get overwritten?
Thanks
RussR,
There is a policy restriction that you have to relieve in
order
for
this
to
work correctly. If you look on a XP Pro machine under
Computer
Configuration - Windows Settings - Security Settings - Local
Policies -
Security Options and look at the properties of the policy
for
"Accounts:
Limit local account use of blank passwords to console logon
only"
that
you
can see the by default this policy is enabled.
The reg hack for this is at:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
-> limitblankpassworduse="0" to disable it.
If you disable this, I'm pretty sure that you can get access
to
the
box
without going through the password ordeal.
I'm not in front of TD right now so I can't be certain where
this
is
in
the
existing components, but if you can't find it you may be
able
to
hard
code
it in to Extra Registry Settings and turn up the build order
pretty
late
so
that it overwrites the default setting.
John Vorchak [eMVP]
thanks what you said to do worked as when my target device
was
finally
up
and running with XPE, I was able to see it on the network.
When
I
logged
onto the target device it self it shows that thetimeI
set
to
share
with
my batch script, did indeed get shared.
There's just one problem though: when I go to access my
XPE
machine
through
"My Network Places" from another machine on the network,
it
won't
let
me
access the files and other shared stuff that resides on
the
XPE
machine.
It
says because of a user restriction. I think this is
because
there
is
only
the default Adminstrator account and no password is set.
I
do
not
want
to
set a password as the target device is headless. Is there
any
way
to
get
past this so that my files are visible to others on the
network
w/o
entering
password and all this junk?
Thanks
message
RussR,
Probably the easiest way is to add the script in the
Extra
Files
in
TD,
then
add a new RunOnce Request (under Extra Resources)
pointing
to
the
script.
The command will execute twice during FBA - which may
fail
but
should
be
able to be ignored with no problem, and then one last
time
after
FBA
has
completed and the image is booted for the first
andwrotethat
should
work
with no problem.
You will need the Net.exe Utility component in your
build.
John Vorchak [eMVP]
I do know how to use the net share command from the
command
prompt
and
putting it into a .bat file would be trivial.
However,
I
do
not
know
how
to
set this to run as a post FBA script especially
ensuring
that
it
runs
after
the network and workgroup and all of that is taken
care
of.
If you could enlighten me, I would appreciate it.
RussR
"John A. Vorchak [eMVP]" <[email protected]>
inrunmessage
RussR,
Probably the easiest way to do it might be tointervention.a
post-FBA
script
that
utilizes the net share command in a batch script.
John Vorchak [eMVP]
On my XPe image, I have installed all the
components
to
enable
File
and
Printer Sharing and Client for Microsoft Networks.
However
to
share
a
folder or drive or other resources, I have to
manually
set
the
sharing
preferences for them after FBA runs and my image
is
usable.
The problem with this is that eventually my target
device
will
be
headless
so I want to be able to pre-set what folders and
files
will
get
shared
upon
first boot thus requring no user
Itwould
also
be
nice
when
deploying images to pre-set the shared resources
either
in
TD
or
some
automated script during first boot.
I have searched through the newsgroups, but have
not
found
any
help
on
this
matter. The same goes with the MSDN stuff.
Is there a way to do this?
Thanks,
RussR