upgrading xubuntu to 24.04, fresh install, but I’d like to copy the output of both dpkg -l and history to a usb stick.

About history: will it copy all commands I executed on all tabs? I work with several tabs simultaneously.

  • unalivejoy@lemm.ee
    link
    fedilink
    English
    arrow-up
    0
    ·
    6 months ago

    First, use lsblk to list your block devices. Note the path containing your usb device. e.g. /dev/sdb1

    Next mount the device to an existing folder or create a new one.

    mkdir -p /mnt/thumbstick
    mount /dev/sdb1 /mnt/thumbstick
    

    Now you can pipe the dpkg output to the usb device.

    dpkg -l > /mnt/thumbstick/packages.txt
    

    Finally, you can unmount the stick to ensure everything is flushed. (optional)

    umount /mnt/thumbstick