apt-get error=100

Asked by asrdata

I've got a remastered Ubuntu CD (10.4) that has been extensively customized and has worked well with UCK for quite some time.
Recently, one of the repositories specified in /etc/apt/sources.list in the customized environment has moved, causing apt-get to fail during the initial remaster process before I can edit /etc/apt/sources.list in the chrooted (customized) environment. I would like to preserve all of the customizations (use the remastered source CD as the source for further remastering) but am unable to get beyond this in UCK 2.2.x through UCK 2.4.3

Is there an edit I can make to one of the UCK scripts or a command line option I can specify to allow me to defer updating the packages until I have fixed or removed the offending repository in the customized /etc/apt/sources.list?

Everything works as expected until apt tries to hit repository that has moved. I really like UCK and really don't want to start from scratch. Any advice or assistance would be greatly appreciated.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Customization Kit Edit question
Assignee:
No assignee Edit question
Solved by:
Wolf Geldmacher
Solved:
Last query:
Last reply:
Revision history for this message
Best Wolf Geldmacher (wolf-womaro) said :
#1

When running uck-gui a copy of the scripts found in /usr/lib/uck/customization-profiles/localized_cd gets copied to ~/tmp/customization scripts unconditionally. If you need to modify the behaviour of the "customize" script run during customization of the rootfs, the easiest approach is to modify the "customize" procedure in the directory specified above so your version gets used in place of the original version from the distribution (your change will be overwritten by an upgrade/reinstall of the package, though).

As an alternative (if you already have run customization at least once, even if it failed): Move ~/tmp/customization-scripts to ~/tmp/customization-scripts.local, modify the "customize" procedure in ~/tmp/customization-scripts.local/customize and the run "uck-remaster location-of-your-iso-file.iso ~/tmp/customization-scripts.local". This will use your locally modified copy of the customization scripts instead of the default ones.

In both cases the function you want to modify is:
function prepare_install()
{
        #try 2 times to avoid slow proxies failures
        apt-get update || apt-get update || failure "apt-get update failed, error=$?"
}
and the modifcation you want to make is:
function prepare_install()
{
       run_console
        #try 2 times to avoid slow proxies failures
        apt-get update || apt-get update || failure "apt-get update failed, error=$?"
}
which will give you a console right before apt-get update is called, allowing you to remove the
offending repository at that point.

Hope this helps.

Revision history for this message
asrdata (info-asrdata) said :
#2

Thanks very much, Wolf for a cogent and helpful answer!
What is the best way for a user to support the UCK project/team?

Revision history for this message
Wolf Geldmacher (wolf-womaro) said :
#3

If you want to help: Please continue to provide feedback (positive and negative) and suggestions on how we could make UCK even more useful for you.