Make bootable arch linux iso of installed system

I have installed Arch Linux in virtual box, with "Awesome" window manager and only required applications with it.
I want to make a bootable iso of this system, which i can carry around with me in pendrive and install in other system.Also, can i make a live usb from it?
Is it possible? If so, please specify the detailed steps. I am a newbie and have been using linux for 2-3 months only. Or, please give the link for the same.
Thanks

Thanks for the reply ewaller.
>Well, not quite.  But, this is a VM.  I assume you want to treat this as an appliance that you can copy to another host that has VirtualBox on it.  All you need to do is copy >the *.vbox file that defines your VM (it is an xml file).  It is about 10 to 20 kbytes in size.  You also need to copy the file that defines the guests "disk".  That is (usually) a *.vdi file. > Those can be tens or hundreds of gigabytes.
>If you actually ran from the pen drive, you could carry that drive from host to host.  If you make a change in the machine while running on one host, thrn shut doen the >VM, and then move to another host, then those changes will follow you.
>If you are just looking to copy the VM to many places; after which the various copies can diverge from each other,  you can just export the appliance to a *.ovf or a *.ova file on > one machine, then import that file on the next host.
In above case, i would only be able to transfer between the virtual machine and that will be restricting.
I did some research and found following thread which is similar to my problem,
http://askubuntu.com/questions/119718/h … d-remaster
but one of the two solution provided here only works on ubuntu(i.e relinux),which was suitable to me and the other one,ie clonezilla to make iso, i haven't tried, but it doesn't do what i want.
Relink does exactly what i want but doesn't work on arch linux.It is a fork of remastersys which is dicontinued and only worked for ubuntu and its related.
I also found this http://null-byte.wonderhowto.com/how-to … o-0131002/
but haven't tried it yet.Also it require to redo all the steps that i have currently done, so i want an alternative.
I also found a simple way, but it is essentially just backuping and restoring and require base install.
https://bbs.archlinux.org/viewtopic.php?id=44805
Atlast, i got this http://systeminstaller.sourceforge.net/   
but there is no description if it will work with arch linux or not.
I want something like above mentioned and i have  no further ideas and searched everywhere, if anyone has any ideas, please suggest something.
Thanks in advance.

Similar Messages

  • Fdisk in arch linux iso

    Hey guys, I've used fdisk on my hdd to create logical partitions. When I used fdisk from arch linux cd about 2 years ago on the same hdd it created logical partitions with 2048 sectors gap before new one. This gap contained extended boot record(same as mbr but for logical partition) and other space for bootloader code.  [sda4 | 2048sectors(EBR for sda5 logical) | sda5]. sda4,5 both logical.
    But when I try to create it now using new arch linux iso it does allow me to create it with the  same gap 2048(as minimum), but if i dont specify at which sector to start the partition, it's default value is different than 2048. For one partition it was 2048+1024, the other of different size had 2048+2048, another had 2048+895 sectors(sector size 512b).  I recall in fdisk of 2010 arch linux iso it had first sector set by default at first available(thus leaving only 2048 gap, which is the least possible). [sda4 | 895+2048 | sda5].
    So why does it offer leaving more space before the partition? Once I created logical partition with the offered gap of 2048+2048 i could then again create new partition inside that gap, which makes me think any space before 2048 sector gap before logical partition is completely unused and unallocated.
    Last edited by Kape (2013-02-07 08:49:18)

    dolby wrote:I've been wondering whats gonna happen if AIF is brought back to a good state again. Will we revent back to using it or stick with arch-install-scripts ?
    Probably fully depends on the quality of AIF. The current method is very KISS and easy.

  • Arch linux iso images

    hello community! would like to know if the new arch linux iso images will continue to happen.Thanks!!

    dolby wrote:I've been wondering whats gonna happen if AIF is brought back to a good state again. Will we revent back to using it or stick with arch-install-scripts ?
    Probably fully depends on the quality of AIF. The current method is very KISS and easy.

  • How to install cinnamon after arch linux core was installed?

    Hi,
    Does anyone know how to install cinnamon desktop environment after arch linux core was installed? It can access internet but no desktop environment now. So how to install and configure cinnamon on arch linux via command?
    Many thanks!

    after arch linux core was installed
    So you finished installing the basesystem or also bootloader, graphics and so on? (https://wiki.archlinux.org/index.php/Beginners'_Guide)
    If you finished installing with the Beginners Guide you need to install the cinnamon package (pacman -S cinnamon). After you installed cinnamon you need a display manager - e.g. lxdm (You can use another one, here's an overview: https://wiki.archlinux.org/index.php/Display_Manager). If you want to use lxdm with cinnamon you have to install the lxdm package (pacman -S lxdm) and enable it afterwards (systemctl enable lxdm.service). If you've done with this just restart, you should see the graphical display manager you installed. If there's a dropdownmenu or something like that (e.g. when you use gdm instead of lxdm) choose cinnamon as display environment and login.
    More informations can be found in the wiki:
    Display Manager: https://wiki.archlinux.org/index.php/LXDM
    Display Environment: https://wiki.archlinux.org/index.php/Cinnamon

  • How to make an Arch Linux Distribution Installer?

    I have made a customized distribution of Arch Linux in vmware.
    I now need to make its installer for deployment.
    How can I do it?
    I have tried Archiso, but it makes new work dir and downloads archlinux again.
    I want to use the current installed and modified linux for the installer.
    Please help

    Hello,
    Basically, I am doing the same right now in VirtualBox.
    There is aif, an installation framework for Arch, which can be customized to install and configure Arch just like you manually did. Use [wiki]Archiso[/wiki] to create a bootable medium and make sure to install aif on it. Now, you need to modify aif in /usr/lib/aif to make exactly the same changes you did to your running system. Then, you can run /sbin/aif from the bootable medium to install your customized Arch.
    Unfortunately, I myself do not know how to change aif to do things to the target system, e.g. install custom packages or manipulate files on the installed system. If someone has already done this or knows how to do, I'd be very grateful if he can share with us.

  • Arch Linux freezes the whole system in VMware

    Hi,
    I use Windows Vista as main OS and I'm trying to install Arch on VMware, the problem is, when I log in into the console and try to type anything else, it will crash my host system (Vista).
    This is very weird because:
    a) I'm running a virtual Gentoo on VMware and it doesn't freeze as Arch.
    b) Arch Linux doesn't freeze the system if I use VirtualBox instead of VMware
    c) I did a clean install of XP (just for testing purposes) and virtual Arch also crashed the system.
    This is confusing me because:
    a) Why does Gentoo work and Arch doesn't? Are there base configurations/software so different that one works and the other doesn't?
    b) Why can VirtualBox handle Arch and VMware can't?
    c) Even a clean install can't handle Arch on VMware? Does this mean it's something wrong in my hardware? How come if Gentoo works on VMware and VirtualBox handles Arch?
    Please note that I can't use VirtualBox, I must use VMware and I would really like to use Arch instead of Gentoo. I'm trying to ditch Gentoo and use Arch but this problem is leaving me no choice than to keep using Gentoo...
    Any ideas?

    Ranguvar wrote:Is it that you can't use VBox, or you must use VMware? There are still other virtual machine apps.
    I know, but I want to use VMware. I don't like VirtualBox that much and VMware is better for me. The other virtual machine apps don't even come close to VMware, at least in my point of view. But it doesn't matter, I want to use VMware.
    Ranguvar wrote:Anyways, is it the Arch install CD that crashes, or is it Arch after it has been installed? Have you read http://wiki.archlinux.org/index.php/Ins … _in_VMWare ?
    After installation, it never crashed during the install as far as I remember.
    Ranguvar wrote:Do you get any specific error messages from Windows? Are you using the latest version of VMware? Can you at least try VirtualBox to help isolate the problem?
    No specific error messages, nothing in the log files, there's nothing anywhere... Yes, I'm using the latest version. What do you mean try VirtualBox to help isolate the problem? I've already used VirtualBox, installed Arch fine and it didn't freeze.
    Ranguvar wrote:This is very odd, and may actually indicate a problem with hardware, or something... a virtual machine should NOT be able to bring down the host, under any circumstances. If it can, both the OS and the virtual machine are bugged. Not too much of a surprise, but yeah.
    My thoughts exactly but how can be an hardware problem if VirtualBox works just fine? How can it be a virtual machine problem if Gentoo works fine on VMware?
    fumbles wrote:Sounds like a problem with VMware (or maybe Vista?) not Arch. Try reinstalling VMware, make sure it is at the lastest version (maybe try even roll back to the previous version), make sure Vista is updated. When you say crash, do you mean BSoD? Or does it just freeze? If it is a BSoD then what is the specific error?
    It just freezes, not a BSOD. It is not a problem with Vista because it also happens on XP. Like I said on my first post, I did a clean install of XP, update all drivers and did all Windows updates, installed latest VMware version and the same thing still happened.
    Joe_Arch wrote:How much ram are you allocating to Arch? Counterintuitively, you might want to try lowering it. If you allocate too much your host OS freaks out.
    I have 2Gb (2x1024Mb) installed on my laptop and I'm using just 256Mb for Arch.
    jacko wrote:someone else was having this issue the other day on irc. the fact is a guest OS should NEVER even come close to crashing the host OS. So more then likely this is a bug in VMware and not arch. What arch packages that is causing the conflict with VMware is unapparent, but it's not likely a bug arch can fix.
    That was me... I'm not saying it's a bug on Arch, but it's weird that Gentoo doesn't have a problem and Arch does. They must differ somehow, one must use some package where the other doesn't or some global system configuration is different from one to the other, there must be some difference, otherwise, they both would freeze or they both would work...

  • Installing Windows XP after Arch Linux already been installed [SOLVED]

    Here is my dilema:
    I have a Fujitsu Lifebook T4010 Laptop with a Wacom Tablet built into the screen. About a month ago I installed Arch Linux on it. It took me a while to get everything working (tablet screen/function buttons/on rotate flip reso) but eventually I got it all working.
    The thing is I feel like I'm not fully taking advantage of its tablet abilities. I want to be able to use it with Photoshop and Flash. I decided I should dual boot it with Windows XP / Arch.
    So I cut down on my /home partition and freed up ~25 gigs of the total 80 gigs for Windows. When I went to install it told me the maximum number of partitions had been met.  I looked it up online and apparently you can only have 4 primary partitions and with the 4 that Arch currently occupies (boot/swap/root/home) it looks like I'm out of luck.
    I'm thinking my only option is to combine my home partition with my root partition to free up a primary partition. People tell me it's easier when you have Windows installed first but to be honest it took me quite some time to get this laptop/tablet up and running and all of it's features working for me how I wanted and I don't want to have to go through it again.
    If anyone has any advice, work arounds,  or could tell me how I would go about safely combining my home and root partition it would be greatly appreciated.
    Thanks a ton,
    Last edited by bladdo (2009-06-13 17:12:09)

    lzs wrote:
    After a second thought, you'd have to move the home partition as well, as the extended partition counts too. I'd start with an arch live cd, cfdisk, delete swap, make extended, 2 logical drives, format the partition, backup, move home's content. then delete home, create new primary, install windows, write grub again, put the new partitions into fstab and tell grub where to find windows.
    EDIT: After a third thought, combining home and root might be easier: Just copy home's content to your root partition (if ther is enough room ...), unmount home, copy the stuff to /home and delete the home partition from fstab. Then delete the old home partition.
    Copying the home's contents to the root partition was what I had in mind. I'm trying to figure out how I would go about doing that though.  If I copy the /home to the root partition from the old home partition - will it automatically pick it up if I delete the fstab entry. Also will it be possible to expand my /root partition after that to take up the space the home partion use to own?

  • [SOLVED]New Arch Linux ISO Installation Help.

    Hi All,
    I am trying to install Arch Linux using new ISO. For some reason I am unable to log into Arch Forums on Windows and I am writing this on my tablet. I will add more info (proper quote, etc.) as soon as I am able to log in a laptop browser. That being said I am trying to install Arch using new ISO. Here is what I did.
    Partition using cfdisk /, /home , /swap and /boot.
    Format all these in ext4.
    Create folders in mnt - root, home, swap, boot.
    mount partitions in mnt folders.
    Pacstrap /mnt base base-devel
    Error
    ERROR: /mnt is not a mount point!
    I install in /mnt/root which probably doesnt touch other partitions like home boot and swap.
    I follow other steps on installation wiki and reboot takes me back to windows.
    What am I doing wrong?
    Thanks.
    Last edited by donniezazen (2012-07-24 22:49:01)

    donniezazen wrote:Partition using cfdisk /, /home , /swap and /boot.
    Format all these in ext4.
    Create folders in mnt - root, home, swap, boot.
    You don't need a root folder. /mnt is the root mount point. Before you mount boot and home:
    mount /dev/sdax /mnt
    where "x" is the number of your /root partition.
    then
    mkdir /mnt/boot
    mount /dev/sdax /mnt/boot
    mkdir /mnt/home
    mount /dev/sdax /mnt/home
    (replace "x" in all the /dev/sdax with the correct partitions.)
    Error
    ERROR: /mnt is not a mount point!
    you should have stopped here and posted or tried to figure out what you did wrong.
    The edited Beginner's Guide is very clear about this. You should read it.
    Last edited by 2ManyDogs (2012-07-24 20:09:24)

  • ArchDL -- Download Latest Arch Linux ISO Image from Mirror

    Hey guys, here is my ArchISO script. To download latest version of iso image from a mirror. I will add more countries/mirros ones I have time. Right now there is only "United States" mirrors. Enjoy.
    EDIT: Alright scrip now know as "ArchDL", and you can find it at
    https://github.com/GoTux/Bash/blob/master/archdl.sh
    Last edited by TuxLyn (2012-11-08 19:42:32)

    TuxLyn wrote:@Pranavg1890, I'll see what I can do. Also, I've created wiki pages at github for all the scripts I released.
    Really? This script is to download the iso, right? so, maybe I'm wrong, but I think downloading the iso and install it to an usb has nothing to do.
    Or are you going to create another script to do that?
    Anyway, about the downloading script.
    What if it parsed the download page, to get all links listed there? With something like:
    curl -s 'https://www.archlinux.org/download/' |sed -n '/id="download-mirrors"/,/\/div/ {/href/ s/.*href="\([^"]*\).*/\1/p; /h5/ s/.*<h5.*> \([^<]*\).*/\1/p}'
    You could get the list of links.
    Also, check this: http://grulos.blogspot.mx/2007/10/find- … irror.html
    Is an script to find the fastest mirror from a list of urls.
    To be really useful the script, it would be better if it autoselected the fastest mirror for you, instead of waiting for you to tell it which mirror to use.
    So, what you think?

  • Gui a'la Arch Linux for building/installing/maintaining E17

    Hi!
    I have made a simple GUI in Dialog / bash for maintaining E17 right now it can build e17 and install it, build and upgrade it and last it can just build e17 (not installing/updating)
    anywya, feel free to try it, but be aware that this is the first version so I AM NOT RESPONSIBLE FOR ANY DAMAGE!!!
    please report errors, and I am sorry for any inconvinience this might cause
    UPDATE: BIG BUG KILLED! UPDATE TO 0.0.4
    Update:
    New version is out
    Buggs are squashed, and some new feutures, like if you are root when installing, it restores ownership of files...and new cleaning of directories is working quite well....also more logging, and more correct logging...
    UPDATE
    New version: New feuture is the ability to use Gensync to do your own repo
    Have fun
    download here: http://www.linuxportalen.com/files/e17_ … 0.6.tar.gz
    it includes pkgbuilds, pkg.list file, and the script itself
    UPDATE: New version of the script, does not require editing the code
    although it has not been properly tested, but it should work
    http://www.linuxportalen.com/files/e17_ … 0.7.tar.gz

    Feutures in the next version of the script is:
    Building and installing E17 from PKGBUILDS
    Building and Upgrading E17 from PKGBUILD
    Building E17 from PKGBUILD (and copy all build-files to a specified directory)
    While building and something goes wrong, You may go back, uncheck those packages that you have already made, and skip the one that gone wrong and continue installing/upgrading/building
    Inbuilt fail-checking
    Upcoming feutures, (although not sure how to do all of it yet)
    Uninstalling of E17 (or specifik packages)
    Gensync (make your own repo)
    download here:
    Anyone has any more ideas?http://www.linuxportalen.com/files/e17_ … 0.3.tar.gz

  • How to make this arch linux xdm theme?

    Hi!
    I search xdm themes and I found this one:
    http://www.abclinuxu.cz/software/system … laseni/xdm
    But there is no Xressource file so if someone can help me to make this theme.
    Thanks
    Cassy.

    When you are a little 'handy' you could try the /etc/X11/xdm directory out of my Zenwalk tgz package at this page: http://www.lontronics.nl/index.php?m=0011
    I was using this package in combination with Zenwalk as TWM extention, but the xdm settings are about the same as in the link you posted. Only difference is the missing picture and clock, but you could add them.
    Just try it;
    - extract the package
    - rename your /etc/X11/xdm to /etc/X11/xdm.res
    - copy the /etc/X11/xdm out of the package to /etc/X11/xdm on your system
    One point; because I was using xdm only in combination with TWM, I had a /etc/X11/xinit/xinitrc file which was starting twm as window manager. The files in /etc/X11/xdm are pointing to /etc/C11/xinit/xinitrc, so it would be wise to check this if you are using more then one window manager, or your setup is different.
    (website is work in progress....)
    Jan
    Last edited by Lontronics (2007-04-04 22:03:42)

  • Arch Linux iso and img metalinks

    I've finally created a script to automatically generate metalinks for the current iso and img downloads using the most recent official mirrorlist
    The generated metalinks are currently listed here: http://xyne.archlinux.ca/arch
    I might move the links page around on the site but the metalink directory should not change. If any of the site admins would like to include these on the downloads page, send me an email so we can work out the optimal way of doing it (e.g. I could create a custom page that you could scrape and show you how to update the metalinks via the web interface when mirrorlists/downloads change).
    For anyone not familiar with metalinks, here's an example of how to use one with aria2c:
    aria2c --follow-metalink=mem -j45 -C45 http://xyne.archlinux.ca/metalinks/archlinux-2009.02-ftp-x86_64.iso.metalink
    aria2c should be capable of downloading from the metalink and the torrent simultaneously but I gave up trying to get it to work after a couple of minutes.
    The Firefox add-on "DownThemAll!" can also handle metalinks.
    archlinux-*-all.metalink contains all of the files. Don't use this link unless you either:
    a) really need all of the files
    b) know how to select files from a metalink
    Last edited by Xyne (2009-04-24 22:05:25)

    Xyne wrote:@Dieter@be
    The post about metalinks on pacman-dev reminded me about this thread. The advantage of the metalinks over torrents, even webseeded torrents, is that you don't need a torrent client to download them. You can use DownThemAll (and maybe other add-ons) to download them directly in Firefox, for example.
    exactly, most download apps (FTP clients, non-torrent P2P clients, most download managers, and browsers, with the exception of Opera) don't support torrents directly. and there are many situations where P2P uploading is banned or frowned upon, like corporate/university networks, places with slow uplink, misconfigured hardware, etc...
    torrents are awesome, but they're not a perfect fit in every situation. metalinks give you alternates, failover options, P2P-like features - so if there's any way for a download to complete, it will. there's the slightly added complexity & effort of getting em in place, but once that's automated it's usually pretty helpful.
    here's a good description of the situation:
    http://www.techradar.com/news/computing … ads-611025

  • Having trouble installing Arch Linux to USB key

    Hello,
    I have read the wiki article, but it doesn't answer my question. I am having trouble installing Arch to a USB key (8GB Sandisk Cruzer). I installled GRUB correctly, it booted, but the flash drive was write-protected. In the fstab file, I have the defaults and noatime flags in there. I have never experienced an error like this, and I don't know how to fix it. I have tried to reboot into the Arch CD and mounted the USB, but it just stalls and displays no output. Obviously, if I boot into my USB (you can still boot into it), and do "nano /etc/fstab", it says that I cannot write. In case you were wondering, I am using the root user. Thank you for all your help!
    EDIT: I have Syslinux, the kernel parameters is RW. If I run mount -o remount,rw /dev/sda1, it tells me something like:
    ata3.00: status: {DRDY ERR}
    ata3.00: error: {IDNF}
    end_request: I/O error, dev sda, sector 21
    Buffer I/o error on device sda1, logical block 0
    EXT4-fs error (device sda1): ext4_remount:4665: Abort forced by user
    I did NOT hit CTRL+C.
    Last edited by aqua123 (2013-09-07 02:01:30)

    I'm a nub, and I think I'll piggy back of aqua's post.  Perhaps we have the same problem
    I have an Asus UX31A with Xubuntu (with grub) currently installed.  I created the bootable USB as per the Arch Wiki UEFI bootable usb page.  I can boot into the main prompt where you can choose "Arch Linux Iso", "shell v1", "shell v2" and "Default prompt."
    Choosing the first option (to get to the the command prompt and begin installing) makes the screen flash once, then just hangs black.  Before the flash I think I see three text lines in the upper left corner, but they flash so fast I can't read them.
    Choosing either of the shell options presents the error:
    "Error loading \EFI\shellx64_v1.efi: Unsupported"  (replace "v1" with "v2" for the other option)
    Any thoughts?

  • Install 2nd instance of Arch Linux without internet connection

    I have successfully install a first instance of Arch Linux using Arch Linux ISO + pacstrap + pacman with internet connection.
    I have updated to latest package database list (/var/lib/pacman/sync) and package cache files (/var/cache/pacman/pkg) in first instance of Arch Linux with "pacman -Swyu".
    Next, I would like to install 2nd instance of Arch Linux without using internet connection.
    I share the "/var/lib/pacman/sync" and "/var/cache/pacman/pkg" via NFS from first Arch Linux instance.
    I boot the 2nd instance with Arch Linux ISO and attempt to install without internet connection.  I mount the two NFS shares from 1st instance to "/var/cache/pacman/pkg" and "/mnt/var/lib/pacman/sync" respectively.  I execute
       # pacstrap -i -c /mnt"
    to start installation.
    I found it is almost impossible with current implementation of pacstrap script.  The pacstrap script always attempt to update package database list with -Sy option.
    I think some amendments on pacstrap script is needed to install Arch Linux without internet connection.

    I made the edit by adding the option -o to do what you want.
    I am too lazy for a feature request right now...
    #!/bin/bash
    # Assumptions:
    # 1) User has partitioned, formatted, and mounted partitions on /mnt
    # 2) Network is functional
    # 3) Arguments passed to the script are valid pacman targets
    # 4) A valid mirror appears in /etc/pacman.d/mirrorlist
    shopt -s extglob
    out() { printf "$1 $2\n" "${@:3}"; }
    error() { out "==> ERROR:" "$@"; } >&2
    msg() { out "==>" "$@"; }
    msg2() { out " ->" "$@";}
    die() { error "$@"; exit 1; }
    in_array() {
    local i
    for i in "${@:2}"; do
    [[ $1 = "$i" ]] && return
    done
    track_mount() {
    mount "$@" && CHROOT_ACTIVE_MOUNTS=("$2" "${CHROOT_ACTIVE_MOUNTS[@]}")
    api_fs_mount() {
    CHROOT_ACTIVE_MOUNTS=()
    { mountpoint -q "$1" || track_mount "$1" "$1" --bind; } &&
    track_mount proc "$1/proc" -t proc -o nosuid,noexec,nodev &&
    track_mount sys "$1/sys" -t sysfs -o nosuid,noexec,nodev &&
    track_mount udev "$1/dev" -t devtmpfs -o mode=0755,nosuid &&
    track_mount devpts "$1/dev/pts" -t devpts -o mode=0620,gid=5,nosuid,noexec &&
    track_mount shm "$1/dev/shm" -t tmpfs -o mode=1777,nosuid,nodev &&
    track_mount run "$1/run" -t tmpfs -o nosuid,nodev,mode=0755 &&
    track_mount tmp "$1/tmp" -t tmpfs -o mode=1777,strictatime,nodev,nosuid
    api_fs_umount() {
    umount "${CHROOT_ACTIVE_MOUNTS[@]}"
    valid_number_of_base() {
    local base=$1 len=${#2} i=
    for (( i = 0; i < len; i++ )); do
    (( (${2:i:1} & ~(base - 1)) == 0 )) || return
    done
    mangle() {
    local i= chr= out=
    unset {a..f} {A..F}
    for (( i = 0; i < ${#1}; i++ )); do
    chr=${1:i:1}
    case $chr in
    [[:space:]\\])
    printf -v chr '%03o' "'$chr"
    out+=\\
    # fallthrough
    out+=$chr
    esac
    done
    printf '%s' "$out"
    unmangle() {
    local i= chr= out= len=$(( ${#1} - 4 ))
    unset {a..f} {A..F}
    for (( i = 0; i < len; i++ )); do
    chr=${1:i:1}
    case $chr in
    if valid_number_of_base 8 "${1:i+1:3}" ||
    valid_number_of_base 16 "${1:i+1:3}"; then
    printf -v chr '%b' "${1:i:4}"
    (( i += 3 ))
    fi
    # fallthrough
    out+=$chr
    esac
    done
    printf '%s' "$out${1:i}"
    dm_name_for_devnode() {
    read dm_name <"/sys/class/block/${1#/dev/}/dm/name"
    if [[ $dm_name ]]; then
    printf '/dev/mapper/%s' "$dm_name"
    else
    # don't leave the caller hanging, just print the original name
    # along with the failure.
    print '%s' "$1"
    error 'Failed to resolve device mapper name for: %s' "$1"
    fi
    fstype_is_pseudofs() {
    # list taken from util-linux source: libmount/src/utils.c
    local -A pseudofs_types=([anon_inodefs]=1
    [autofs]=1
    [bdev]=1
    [binfmt_misc]=1
    [cgroup]=1
    [configfs]=1
    [cpuset]=1
    [debugfs]=1
    [devfs]=1
    [devpts]=1
    [devtmpfs]=1
    [dlmfs]=1
    [fuse.gvfs-fuse-daemon]=1
    [fusectl]=1
    [hugetlbfs]=1
    [mqueue]=1
    [nfsd]=1
    [none]=1
    [pipefs]=1
    [proc]=1
    [pstore]=1
    [ramfs]=1
    [rootfs]=1
    [rpc_pipefs]=1
    [securityfs]=1
    [sockfs]=1
    [spufs]=1
    [sysfs]=1
    [tmpfs]=1)
    (( pseudofs_types["$1"] ))
    newroot=/mnt
    hostcache=0
    copykeyring=1
    copymirrorlist=1
    offline=0
    usage() {
    cat <<EOF
    usage: ${0##*/} [options] root [packages...]
    Options:
    -C config Use an alternate config file for pacman
    -c Use the package cache on the host, rather than the target
    -d Allow installation to a non-mountpoint directory
    -G Avoid copying the host's pacman keyring to the target
    -i Avoid auto-confirmation of package selections
    -M Avoid copying the host's mirrorlist to the target
    -o Do not update the pacman cache for offline installation
    -h Print this help message
    pacstrap installs packages to the specified new root directory. If no packages
    are given, pacstrap defaults to the "base" group.
    EOF
    if [[ -z $1 || $1 = @(-h|--help) ]]; then
    usage
    exit $(( $# ? 0 : 1 ))
    fi
    (( EUID == 0 )) || die 'This script must be run with root privileges'
    while getopts ':C:cdGiMo' flag; do
    case $flag in
    C)
    pacman_config=$OPTARG
    d)
    directory=1
    c)
    hostcache=1
    i)
    interactive=1
    G)
    copykeyring=0
    M)
    copymirrorlist=0
    o)
    offline=1
    die '%s: option requires an argument -- '\''%s'\' "${0##*/}" "$OPTARG"
    die '%s: invalid option -- '\''%s'\' "${0##*/}" "$OPTARG"
    esac
    done
    shift $(( OPTIND - 1 ))
    (( $# )) || die "No root directory specified"
    newroot=$1; shift
    pacman_args=("${@:-base}")
    if (( ! hostcache )); then
    pacman_args+=(--cachedir="$newroot/var/cache/pacman/pkg")
    fi
    if (( ! interactive )); then
    pacman_args+=(--noconfirm)
    fi
    if (( ! offline )); then
    pacman_args+=(-y)
    fi
    if [[ $pacman_config ]]; then
    pacman_args+=(--config="$pacman_config")
    fi
    [[ -d $newroot ]] || die "%s is not a directory" "$newroot"
    if ! mountpoint -q "$newroot" && (( ! directory )); then
    die '%s is not a mountpoint!' "$newroot"
    fi
    # create obligatory directories
    msg 'Creating install root at %s' "$newroot"
    mkdir -m 0755 -p "$newroot"/var/{cache/pacman/pkg,lib/pacman,log} "$newroot"/{dev,run,etc}
    mkdir -m 1777 -p "$newroot"/tmp
    mkdir -m 0555 -p "$newroot"/{sys,proc}
    # always call umount on quit after this point
    trap 'api_fs_umount "$newroot" 2>/dev/null' EXIT
    # mount API filesystems
    api_fs_mount "$newroot" || die "failed to setup API filesystems in new root"
    msg 'Installing packages to %s' "$newroot"
    if ! pacman -r "$newroot" -S "${pacman_args[@]}"; then
    die 'Failed to install packages to new root'
    fi
    if (( copykeyring )); then
    # if there's a keyring on the host, copy it into the new root, unless it exists already
    if [[ -d /etc/pacman.d/gnupg && ! -d $newroot/etc/pacman.d/gnupg ]]; then
    cp -a /etc/pacman.d/gnupg "$newroot/etc/pacman.d/"
    fi
    fi
    if (( copymirrorlist )); then
    # install the host's mirrorlist onto the new root
    cp -a /etc/pacman.d/mirrorlist "$newroot/etc/pacman.d/"
    fi
    # vim: et ts=2 sw=2 ft=sh:

  • Install Arch Linux with UEFI and GPT

    Hi, I purchased a new laptop and I created a partition with Windows 8 (default OS on laptop) and another partition where I want to install Arch Linux.
    When I tried to install Arch Linux not boot from CD. After searching in Google I downloaded the latest Arch Linux ISO (2012-12-01) and tried again.
    This time CD started without problems but when I used cfdisk showed an error with GPT partition. I went back to search in Google and I read about gdisk and gfdisk and I try it but when I partitioning to install Arch Linux partition show that may cause damage. I searched and searched without success and I wonder if there is a Arch Linux GPT install guide or if someone knows how to install Arch Linux with GPT and a Windows 8 partition in UEFI.
    Thanks and regards.

    Hi again, finally I got "install" Arch Linux but when I reboot the follow message appears:
    "No Booteable Device, Hit any key."
    I don't know if I broke Windows Boot Manager, UEFI or both...
    I tried to reinstall GRUB but was unsuccessful.
    Can anyone help me?
    Thanks and regards.

Maybe you are looking for