[Bug 1963725] Re: subiquity curtin apt-get update fails

2024-07-29 Thread Will Rouesnel
I have resolved at least one variant of this problem:

My issue was I was repacking an Ubuntu ISO (24.04) to use with
autoinstall.yaml.

The problem was that when the /cdrom directory was getting mounted, the
root - i.e. /cdrom would have permissions rwx-- (0700).

This was caused by how I did the repack: since I copied the filesystem
to a temporary directory, and then built a new ISO from there, the
*root* filesystem was being stored to the disk with (0700) permissions.

For whatever reason, this only turns up in the subiquity environment
during installation, not the "Try Ubuntu" live environment.

The fix for me was to force the dir-mode when rebuilding the ISO with
Xorriso:

My xorriso command now looks like this:

xorriso -as mkisofs \
-V "$(echo "${output_iso##*/}" | cut -c -32)" \
-o "${output_iso}" \
--grub2-mbr "${work_dir}/boot_hybrid.img" \
--protective-msdos-label \
-partition_offset 16 \
--mbr-force-bootable \
-append_partition 2 28732ac11ff8d211ba4b00a0c93ec93b 
"${efi_partition_img}" \
-appended_part_as_gpt \
-iso_mbr_part_type a2a0d0ebe5b9334487c068b6b72699c7 \
-c "/boot.catalog" \
-b "/boot/grub/i386-pc/eltorito.img" \
-no-emul-boot \
-boot-load-size 4 \
-boot-info-table \
--grub2-boot-info \
-eltorito-alt-boot \
-e '--interval:appended_partition_2:::' \
-no-emul-boot -J \
-dir-mode 0755 \
"${work_dir}" ; then

The key line is `-dir-mode 0755` - that fixed the problem entirely.

If you are having issues with apt-get in subiquity, *are you using a
repacked ISO?* Because that might be the problem.

IMO: subiquity should handle this situation though. It has full
permissions to control how /cdrom gets mounted and with what permissions
- it should set them wide open.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2024-05-03 Thread Chris Bianchetti
I was stuck on this for awhile with 22.04.4 but it turned out to be
permissions issue on my xorriso customized image iso. Here's how I was
able to clearly see what was causing the error:

For me the error was:
2024-05-03 23:38:22,203 ERROR root:30 finish: 
subiquity/Install/install/configure_apt: FAIL: Command '['systemd-run', 
'--wait', '--same-dir', '--property', 'SyslogIdentifier=subiquity_log.2237', 
'--property', 'PrivateMounts=yes', '--setenv', 
'PATH=/snap/subiquity/5495/bin:/snap/subiquity/5495/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/subiquity/5495/bin:/snap/subiquity/5495/sbin',
 '--setenv', 'PYTHONPATH=:/sn
ap/subiquity/5495/lib/python3.10/site-packages', '--setenv', 
'PYTHON=/snap/subiquity/5495/usr/bin/python3.10', '--setenv', 
'SNAP=/snap/subiquity/5495', '--', '/s
nap/subiquity/5495/usr/bin/python3.10', '-m', 'curtin', '--showtrace', '-vvv', 
'--set', 'json:reporting={"subiquity": {"type": "journald", "identifier": 
"curtin_
event.2237.3"}}', 'in-target', '-t', '/tmp/tmpekbt6rtp/mount', '--', 'apt-get', 
'update']' returned non-zero exit status 100.

Which translates to this command:
systemd-run \
--wait \
--same-dir \
--property SyslogIdentifier=subiquity_log.2237 \
--property PrivateMounts=yes \
--setenv 
PATH=/snap/subiquity/5495/bin:/snap/subiquity/5495/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/subiquity/5495/bin:/snap/subiquity/5495/sbin
 \
--setenv PYTHONPATH=:/snap/subiquity/5495/lib/python3.10/site-packages \
--setenv PYTHON=/snap/subiquity/5495/usr/bin/python3.10 \
--setenv SNAP=/snap/subiquity/5495 \
-- \
/snap/subiquity/5495/usr/bin/python3.10 \
-m curtin \
--showtrace \
-vvv \
--set json:reporting={"subiquity": {"type": "journald", "identifier": 
"curtin_event.2237.3"}} \
in-target \
-t /tmp/tmpekbt6rtp/mount \
-- \
apt-get update

I took the "--set json:reporting={"subiquity": {"type": "journald",
"identifier": "curtin_event.2237.3"}} \" part out and ran it.

I get this:
Running as unit: run-u40.service
Finished with result: exit-code
Main processes terminated with: code=exited/status=100
Service runtime: 2.153s
CPU time consumed: 1.892s

I run systemctl status run-u40.service and which shows the unit file
"/run/systemd/transient/run-u40.service"

Unit file:
# This is a transient unit file, created programmatically via the systemd API. 
Do not edit.
[Unit]
Description=/snap/subiquity/5495/usr/bin/python3.10 -m curtin --showtrace -vvv 
in-target -t /tmp/tmpekbt6rtp/mount -- apt-get update

[Service]
SyslogIdentifier=subiquity_log.2237
PrivateMounts=yes
WorkingDirectory=/root
Environment="PATH=/snap/subiquity/5495/bin:/snap/subiquity/5495/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/subiquity/5495/bin:/snap/subiquity/5495/sbin"
 "PYTHONPATH=:/snap/subiquity/5495/lib/python3.10/site-packages" 
"PYTHON=/snap/subiquity/5495/usr/bin/python3.10" "SNAP=/snap/subiquity/5495"
ExecStart=
ExecStart="/snap/subiquity/5495/usr/bin/python3.10" "-m" "curtin" "--showtrace" 
"-vvv" "in-target" "-t" "/tmp/tmpekbt6rtp/mount" "--" "apt-get" "update"


Set up environment:
export 
PATH=/snap/subiquity/5495/bin:/snap/subiquity/5495/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/subiquity/5495/bin:/snap/subiquity/5495/sbin
export PYTHONPATH=:/snap/subiquity/5495/lib/python3.10/site-packages
export PYTHON=/snap/subiquity/5495/usr/bin/python3.10
export SNAP=/snap/subiquity/5495

Now run the command to see the error:
/snap/subiquity/5495/usr/bin/python3.10 -m curtin --showtrace -vvv in-target -t 
/tmp/tmpekbt6rtp/mount -- apt-get update

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-05-02 Thread Launchpad Bug Tracker
Status changed to 'Confirmed' because the bug affects multiple users.

** Changed in: subiquity (Ubuntu)
   Status: New => Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-05-02 Thread Paul Lambert
I believe I have if not the same but a similar issue. OS is Ubuntu 22.04.
Logs attached.

** Attachment added: "ubuntu.zip"
   
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+attachment/5585807/+files/ubuntu.zip

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Re: [Bug 1963725] Re: subiquity curtin apt-get update fails

2022-03-04 Thread Michael Hudson-Doyle
We need to do a better job of surfacing "your mirror is broken" errors to
the user.

On Sat, 5 Mar 2022, 13:50 MercSniper, <1963...@bugs.launchpad.net>
wrote:

> Seems to be it. I've been fighting this all day. Can't believe the
> mirror hadn't synced in the last 6+ hours.
>
> --
> You received this bug notification because you are subscribed to
> subiquity in Ubuntu.
> https://bugs.launchpad.net/bugs/1963725
>
> Title:
>   subiquity curtin apt-get update fails
>
> To manage notifications about this bug go to:
>
> https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions
>
>

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-03-04 Thread MercSniper
Seems to be it. I've been fighting this all day. Can't believe the
mirror hadn't synced in the last 6+ hours.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-03-04 Thread Dan Bungert
Mar 04 19:12:56 ubuntu-server subiquity_log.2013[2214]: E: Failed to
fetch http://mirror.us-midwest-1.nexcess.net/ubuntu/dists/focal-
backports/universe/i18n/Translation-en.xz  File has unexpected size
(15168 != 15416). Mirror sync in progress? [IP: 208.69.120.125 80]

Would you retry with a different mirror?

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-03-04 Thread MercSniper
/var/log/curtin does not exist at crash prompt. Did a redirect on
journalctl to get the attached.

** Attachment added: "debug.log"
   
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+attachment/5565916/+files/debug.log

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1963725] Re: subiquity curtin apt-get update fails

2022-03-04 Thread Dan Bungert
Thanks @MercSniper.

Sadly the crash file doesn't have the curtin log, and the details on
what apt is unhappy about will be there.  Are you able to share the
contents of /var/log/curtin/install.log?

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1963725

Title:
  subiquity curtin apt-get update fails

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1963725/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs