|
|
Subject: RE: Post-Scripts Not Working - msg#00007
List: linux.suse.autoinstall
Ahh, I must have missed the one "]", and I didn't realize I can have
separate commands on a different line. Thank you Carsten!
~~RK
-----Original Message-----
From: Carsten Dumke [ mailto:carsten.dumke@xxxxxxx]
Sent: Sunday, April 29, 2007 3:08 AM
To: King, Richard (CE1 UNIX Admin); opensuse-autoinstall@xxxxxxxxxxxx
Subject: RE: [opensuse-autoinstall] Post-Scripts Not Working
Hello Richard,
You wrote on Saturday, April 28, 2007 12:42 AM:
> SuSE: 10.1
>
> Hello All!
>
> I've been trying to run 2 post-scripts, and it appears they are not
> working. I'll I am trying to is modify 2 files, /etc/passwd &
> /etc/shadow.
>
> This is what I have in the autoyast file:
>
> <scripts>
> <post-scripts config:type="list">
> <script>
> <debug config:type="boolean">false</debug>
> <feedback config:type="boolean">false</feedback>
> <filename>nispasswd</filename>
> <interpreter>shell</interpreter>
> <location></location>
> <network_needed
> config:type="boolean">false</network_needed>
> <source><![CDATA[cat /etc/passwd | sed
> 's/+::::::/+::0:0:::/g'] >> /etc/passwd.tmp mv /etc/passwd.tmp
> /etc/passwd ]]></source>
Try this one:
<source><![CDATA[#!/bin/sh
cat /etc/passwd | sed 's/+::::::/+::0:0:::/g' > /etc/passwd.tmp mv
/etc/passwd.tmp /etc/passwd ]]></source>
> </script>
> <script>
> <debug config:type="boolean">false</debug>
> <feedback config:type="boolean">false</feedback>
> <filename>nisshadow</filename>
> <interpreter>shell</interpreter>
> <location></location>
> <network_needed
> config:type="boolean">false</network_needed>
> <source><![CDATA[cat /etc/shadow | sed
> 's/+/+::0:0:0::::/g']
> >> /etc/shadow.tmp mv /etc/shadow.tmp /etc/shadow ]]></source>
Try this one:
<source><![CDATA[#!/bin/sh
cat /etc/shadow | sed 's/+/+::0:0:0::::/g' > /etc/shadow.tmp
mv /etc/shadow.tmp /etc/shadow
]]></source>
> </script>
> </post-scripts>
> </scripts>
>
> As you can see, I am just trying to edit the passwd & shadow
> files. These scripts are within the <profile></profile> tags.
> Can someone help me understand why these post scripts are not
> working? Is there a better way to edit these files?
Leave out the ']' in the sed-commands and put the mv-commands
on a new line.
After the installation You can find the scripts in
/var/adm/autoinstall/scripts and their debug-logs in
/var/adm/autoinstall/logs
HTH.
Best regards,
Carsten
Was this page helpful?
Thread at a glance:
Previous Message by Date:
click to view message preview
RE: Removal of Packages
Uwe,
Thank you very much for your reply, very much appreciated!
Quick question: After I download the file (10.1_root_fix_v0.2), is there
anything else I need to do to "enable" the driverupdate? This is what I have so
far in the install directory. Thanks again Uwe!
|-- 10.1_root_fix_v0.2
|-- ARCHIVES.gz
|-- COPYING
|-- COPYING.de
|-- COPYRIGHT
|-- COPYRIGHT.de
|-- ChangeLog
|-- INDEX.gz
|-- LICENSE.TXT
|-- LIESMICH
|-- LIESMICH.DOS
|-- README
|-- README.BETA.DOS
|-- README.DOS
|-- SuSEgo.ico
|-- TIME
|-- add_on_products
|-- autorun.inf
|-- boot
|-- content
|-- content.asc
|-- content.key
|-- control.xml
|-- directory.yast
|-- docu
|-- dosutils
|-- gpg-pubkey-0dfb3188-41ed929b.asc
|-- gpg-pubkey-1d061a62-427a396f.asc
|-- gpg-pubkey-307e3d54-44201d5d.asc
|-- gpg-pubkey-3d25d3d9-36e12d04.asc
|-- gpg-pubkey-9c800aca-40d8063e.asc
|-- ls-lR.gz
|-- media.1
|-- pubring.gpg
|-- suse
|-- updates
`-- yast
~~RK
-----Original Message-----
From: Uwe Gansert [mailto:ug@xxxxxxx]
Sent: Wednesday, May 02, 2007 4:02 AM
To: opensuse-autoinstall@xxxxxxxxxxxx
Subject: Re: [opensuse-autoinstall] Removal of Packages
On Friday 27 April 2007 21:21, King, Richard (CE1 UNIX Admin) wrote:
> SuSE Version: 10.1
>
> The install went fine, however, the packages that I want removed, were
> installed. I have the remove-packages section within the
> <software></software> tag. Anything else I am missing?
10.1 had a bug in the <remove-packages> section.
There is a driverupdate on ftp://ftp.suse.com/pub/people/ug/autoyast
that you can try but keep in mind, packages that are required(!) by a pattern
can't be removed by autoyast. But the games should not be required in that way
and so they should be removeable.
--
ciao, Uwe Gansert
Uwe Gansert, Server Technologies Team
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
Business: http://www.suse.de/~ug
--
To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-autoinstall+help@xxxxxxxxxxxx
Next Message by Date:
click to view message preview
Re: Removal of Packages
On Wednesday 02 May 2007 16:08, King, Richard (CE1 UNIX Admin) wrote:
> Quick question: After I download the file (10.1_root_fix_v0.2), is there
> anything else I need to do to "enable" the driverupdate? This is what I
> have so far in the install directory. Thanks again Uwe!
>
> |-- 10.1_root_fix_v0.2
> |-- ARCHIVES.gz
> |-- COPYING
...
you have to run the patch. It's a shell script and it will create a
file "driverupdate". You don't need the 10.1_root_fix_v0.2 on the
installation source. Just the created "driverupdate"
--
ciao, Uwe Gansert
Uwe Gansert, Server Technologies Team
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
Business: http://www.suse.de/~ug
Previous Message by Thread:
click to view message preview
RE: Post-Scripts Not Working
Uwe,
Thanks again for the sound advice.
~~RK
-----Original Message-----
From: Uwe Gansert [mailto:ug@xxxxxxx]
Sent: Wednesday, May 02, 2007 4:06 AM
To: opensuse-autoinstall@xxxxxxxxxxxx
Subject: Re: [opensuse-autoinstall] Post-Scripts Not Working
On Sunday 29 April 2007 11:07, Carsten Dumke wrote:
> Try this one:
>
> <source><![CDATA[#!/bin/sh
> cat /etc/passwd | sed 's/+::::::/+::0:0:::/g' > /etc/passwd.tmp mv
> /etc/passwd.tmp /etc/passwd ]]></source>
and setting debug=true and feedback=true is a good idea in such a case, where a
script seems to fail, too.
> > <script>
> > <debug config:type="boolean">false</debug>
> > <feedback config:type="boolean">false</feedback>
--
ciao, Uwe Gansert
Uwe Gansert, Server Technologies Team
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
Business: http://www.suse.de/~ug
--
To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-autoinstall+help@xxxxxxxxxxxx
Next Message by Thread:
click to view message preview
verifying the profile
i tried to verify a profile according to this page :
http://www.suse.com/~ug/autoyast_doc/Profile.DTD.html
this failed on sles 10 :
/usr/share/YaST2/schema/autoyast/rng/partitioning.rng:263: element
define: Relax-NG parser error : Some defines for label needs the combine
attribute
Relax-NG schema /usr/share/YaST2/schema/autoyast/rng/profile.rng failed
to compile
am i doing something completely incorrectly ?
--
Rich
|
|