Arch Linux running on Asus Transformer T100/T100TA... sort of.

I'm not really asking for help here (can't find an appropriate place to put this post), but more to show off my accomplishment with this tablet.
As the thread title says, I've gotten Arch Linux to run on the Asus T100TA which is a quite annoying little thing. I haven't documented the steps myself, however, I remember exactly what I have done, and in order to get the live image to at least run on this tablet, here are the steps I did:
(you'll maybe need 2 USB drives, seems to be the easiest way)
1. Create an ISO using the archiso set as you normally would (except you won't really need the ISO itself) OR if you can figure it out yourself, install the base image to the USB drive (either architecture will do, but I recommend i686 since the processor is 32 bit as well)
https://wiki.archlinux.org/index.php/Archiso
This step will be unnecessary as of May, as the live images onwards on the main download site will already contain the 3.14 or newer kernels.
2. After the image building successfully finishes, copy all the contents from (PROFILE)/work/iso/ (except root-image squashfs files) to a FAT32 formatted USB drive (1). This is to simply create a bootloader drive that will allow us for later swapping the USB drives.
3. Download an ia32 version of grub. Any will do as long as it can boot up on the tablet.
http://www.supergrubdisk.org/category/download/supergrub2diskdownload/
This one works, download the standalone IA-32/i386 EFI and paste it in (USB Drive (1))/EFI/boot/bootia32.efi .
(use latest versions, no matter if it's unstable)
4. Now you need to make a grub.cfg. The one I made looks like this
menuentry 'Arch Linux i686'{
echo 'Loading Linux core repo kernel ...'
linux /arch/boot/i686/vmlinuz noefi nomodeset archisobasedir=arch archisolabel=ARCH_201404
echo 'Loading initial ramdisk ...'
initrd /arch/boot/i686/archiso.img
menuentry 'Arch Linux x86_64'{
echo 'Loading Linux core repo kernel ...'
linux /arch/boot/x86_64/vmlinuz noefi nomodeset archisobasedir=arch archisolabel=ARCH_201404
echo 'Loading initial ramdisk ...'
initrd /arch/boot/x86_64/archiso.img
NOTE: If you're using a later live image build, I advise to change the date accordingly. It's not necessary to do so, since the mount by label doesn't work, however, I like to keep everything intact.
noefi flag seems unnecessary as well, though I have added it to prevent some kernel panics from happening, for just in case. It works without it, still, however you need the nomodeset flag or else you'll get a black screen!
I'm not entirely sure where the grub.cfg goes, but I've put it in USB Drive(1)/boot/grub/ , /EFI/grub/ and in /EFI/boot/grub/ just to make it sure that it works.
5. Create an ext2/3/4 (recommended ext2 for flash drives, not to wear it out) USB drive (2) and copy the arch folder to the root of the USB drive (2)
---- BOOT PROCESS ----
Before this step, ensure that Secure Boot is set to OFF in the Aptio setup. Otherwise it will throw up an error in a red box crying it's not signed.
6. Plug in the USB drive (1) into a USB port and while powering on the tablet, tilt the escape key to pop up a boot menu.
7. Select UEFI: (your USB drive (1))
8. GRUB 2 will pop up. If you're running the SuperGrubDisk version, you're gonna have to go to Everything and then scroll down until it says something like
(hd0, msdos1)/boot/grub/grub.cfg
and click on it to open the configuration data manually created.
9. Simply select your desired version of Arch Linux live distro to boot.
10. VOILAaa, not really... It'll pop up with a mount error saying it's a wrong FS to mount. This is where you plug in your USB drive (2) in place of the first one.
11. Type in:
# mount /dev/sda1 /run/archiso/bootmnt
# exit
12. Congratulations, you're running Arch Linux on your ASUS Transformer T100TA tablet!
This is as far as I have went into running it. Installing it on a HDD would require mounting the mmcblk partitions, which I haven't looked into yet. For a start, I'd just recommend installing it on a USB drive, though you'd have to own one of the USB OTG converters or a USB hub. The screen is spammed with the mmcblk0rpmb timeout errors though and that is annoying. It stops after a while when it stops trying. Reboot doesn't work either, seems like acpi is broken.
You could do it with a single usb drive, though it requires some knowledge of this tablet's EFI because it disallowed me from running a kernel on another partition other than FAT32. Grub pops up with an error:
can't unload EFI services
or something like that.
I've also tried putting the USB Drive (2) in during grub and it pops up with an error with invalid sector sizes. That was to be expected.
btw I know it's my first post, I'm just here to share this with you. I never had the need to ask for help but when absolutely necessary.
PICS OF IT RUNNING
Some USB devices aren't visible, like the camera.
A custom partition layout without the recovery partitions. Yours may differ.
Last edited by xan1242 (2014-04-13 22:54:46)

I haven't tried much other than getting this live image to run on this machine. I'll attempt to install the base image using my desktop computer with the appropriate drivers and see how that goes. (or just install the wifi driver)
That guy really made it to work much better than I imagined it to work at all! I'll see what can be done using the same drivers, though running Ubuntu seems tempting as well. He even got the touchscreen to work, which is really awesome. It seems that he also merged the drivers into the kernel image, which is going to be a challenge in Arch.
Since he's using the 64 bit build of Ubuntu, I'll try it with x86_64 Arch as well to try and use his guide to make the drivers to work.
EDIT: I have successully installed the base to an external drive and booted it on the tablet, however since the base was installed externally on another machine, I need to regenerate initrd. It boots on the fallback ramdisk, but still no wifi and the screen is spammed even more with the timeout errors. I've seen topics on Raspberry Pi having a similar issue and that it was repaired using some kernel flags, but I am not sure if those will work with the tablet. Also, using the bootflags jfwells used on Ubuntu work here as well, and gives full resolution output now. Wifi doesn't work. ip link doesn't give any signs of a wifi card present.
EDIT2: Got Arch up and running relatively nicely on the tablet now. Though it is in the same state as the last edit in terms of functionality, it works I'd say well enough to be considered usable. I couldn't make the wireless card to work, for some strange reason, so I got a RT73 USB card (Edimax EW-7318USg to be precise, had to use 2 USB ports) and installed stuff on to the tablet. I ran X without a desktop manager, and the X apps worked fine, even with the touch screen (emulating a mouse, no right click) and I ran XFCE4 on it without a problem (with compositing).
It simply needs more developed drivers on it, that's mostly it. The state is exactly the same as Ubuntu 14.04 that jfwells made to work (minus the wifi). I haven't played with the sound, either, due to the warning he posted, but I believe it works as it does in Ubuntu.
The steps I made are as follows:
1. Simply made another live ISO with the archiso set
2. dd'd the image to a USB drive
3. On the second USB drive I created two GPT partitions (200 - 300 MB for ESP, everything else ext2)
4. Booted the live archiso USB drive
5. Installed the base to the second USB drive while being mounted like this: ext2 partition -> /mnt and ESP -> /mnt/boot
6. Installed GRUB x86_64-efi to simply generate a configuration
7. Installed wireless utilities as well as everything else needed to make it to work
8. To ensure bootability on the tablet, again, I put the IA32 GRUB to the ESP in /EFI/boot/bootia32.efi
9. I have edited the grub.cfg, can't exactly remember with what, but this is what it looks like
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Arch Linux, with Linux core repo kernel' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-core repo kernel-true-(hd0,gpt2)' {
set gfxpayload=keep
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,gpt1'
echo 'Loading Linux core repo kernel ...'
linux /vmlinuz-linux root=/dev/sda2 video=VGA-1:1368x768e reboot=pci,force sdhci.debug_quirks=0x8000 rw quiet
echo 'Loading initial ramdisk ...'
initrd /initramfs-linux.img
menuentry 'Arch Linux, with Linux core repo kernel (Fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-core repo kernel-fallback-(hd0,gpt2)' {
set gfxpayload=keep
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,gpt1'
echo 'Loading Linux core repo kernel ...'
linux /vmlinuz-linux root=/dev/sda2 video=VGA-1:1368x768e reboot=pci,force sdhci.debug_quirks=0x8000 rw quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initramfs-linux-fallback.img
### END /etc/grub.d/10_linux ###
I simply added the kernel flags jfwells added. It needs that root flag, or else it will not boot. I can't figure out the UUIDs though. It will reboot, but it will not shut down.
10. Boot up your second USB drive on the tablet and... IMPORTANT - Boot with the fallback ramdisk - or else you're going to experience non functional input
11. After booting it, you'll get the annoying mmcblk timeout spamming the screen. I haven't figured out how to fix it, but to hide it, type in
# dmesg -n 1
12. Generate another ramdisk (forgot the command, but search function should serve you)
13. Reboot with the normal ramdisk now.
14. After setting up the wireless connection, rock on with the pacman!
At this point I installed a bunch of stuff, like Intel GPU drivers, xorg, xfce4, ntfs-3g, gparted,  and among other stuff I personally test stuff with.
I couldn't mount the mmcblk partitions to at least somehow be able to edit data on the Windows partitions or the disk as a whole.
Anybody willing to help getting Arch to run on this tablet is welcome.
EDIT3: Internal WiFi working! Simply added "sdhci.debug_quirks=0x8000" flag.
Last edited by xan1242 (2014-04-13 23:35:26)

Similar Messages

  • [Bounty] Free Macbook Pro to get Arch Linux running on Amazon's EC2

    First, the details:
    I will purchase a lowest–end Macbook Pro 13″ ($US 1,200 on Apple's store, new) for the first person to deliver to me a working set of step–by–step instructions for installing the latest Arch Linux on top of Amazon's EC2 platform.
    Caveats & Rules:
    - I don't care how long it takes you—there's a good chance I'm doing something absolutely stupid in my noobishness that's causing the problems I've been experiencing; if it takes you half an hour to make a working AMI, and produce instructions to do such… you just won yourself a Macbook Pro for half an hour's work. Booyah!
    - Again, I say, I don't care how long it takes you—if you don't produce a working set of instructions, there will be no payout, even if you spend 200 hours trying (as I already have!). It's a bounty, not a work contract d-:
    - You must provide me with instructions that work for me (as I don't intend to use your AMI, but rather modify the steps that worked for you a bit at a time until I arrive at an AMI configured exactly as I want it). If you arrive at a working AMI, and can reproduce your steps successfully locally, but they can't be made to work for me, I may be able to go about procuring alternative hardware for myself on which to preform the steps, or taking other measures to reproduce your environment; but the bottom line is I will not shell out until I can, personally, produce a working AMI running Arch Linux.
    - The instructions are considered to be "working" when I can successfully SSH into the root account on an instance instantiated from an AMI created by following the instructions using the key generated by EC2.
    - Your instructions must work both for x86_32 and x86_64 instance types; however, this shouldn't be too much of a problem, as (barring any weirdness) anything that works on x86_32 should be easily made to work on x86_64.
    - Instructions that involve instantiating an intermediate bundling host (say, a CentOS or Fedora Core instance) and then installing Arch to a loopback filesystem using a statically–built pacman are much preferred to instructions that involve me having to install and package Arch locally and then ship it up to S3, because my upstream is unimaginably slow and I eventually will need to create something between eight and twenty different AMIs (see below). But anything that works will be accepted.
    - If you don't want a Macbook Pro, alternative payment methods may be arranged, though you need to contact me before you start and arrange these, as there's only so much I can do.
    - If you are in any way confused or unsure of what I'm offering here, please contact me before you start (see below for contact info)
    Backstory:
    I set up the first AMI for Arch Linux on Amazon, but unfortunately, I did some really stupid things (hey, I was completely new to Linux at the time, gimmie a break!). The root filesystem was limited to 1GB, there was a whole bunch of software that really was completely unnecessary (WiFi drivers? on a virtualized server? seriously?), there were no kernel modules provided… and so on.
    So, after running all my stuff on instances of that for a while, I finally got fed up and found the time to start setting up a newer, cleaner AMI. Unfortunately, I made the mistake of deleting my old AMI before starting work on the first. Now I find myself completely unable to create an AMI that will work whatsoever, and I cannot for the life of me figure out why.
    I've already invested 200 or so hours of my personal time since deleting my original, broken AMI; I'm very fed up and in badly need of working instances. I tried every method I could think of; running the Arch installer from a LiveCD locally and then bundling the running (and thus proved working) Arch install and shipping it off to S3; installing Arch on a loopback filesystem locally, cloning it to a local partition, booting to it to ensure it works, and shipping it off to S3; installing Arch on a loopback filesystem on a remote bundling host running CentOS or whatever and then shipping it off to S3… I've tried installing nothing but the essentials, I've tried installing everything the installer offers… I've tried to do my best to remember the exact steps I took the first time around, years ago, and reproduce them exactly… nothing has worked.
    If I take EC2 out of the equation, and install the images I've prepared locally, they work. If I take Arch out of the equation, and install, say, CentOS instead, and then ship it off to EC2, it works. The only time I have problems is when I attempt to install Arch Linux specifically on EC2 specifically; the exact use–case I need.
    I've run into a lot of problems along the way, and fixed them as I go, but I universally end up with an AMI that, once instantiated, does not successfully boot. Worse yet, I get absolutely no output from the console (provided by the ec2-get-console command–line tool) to help me debug the problem. I can't give you any more specifics beyond this to help you, because I don't want to insinuate some idea that will cause you to make some little stupid mistake that I also made, thus dooming the project.
    Contact:
    For more info of any sort, please hit me up on Google Talk or Jabber (… or any other XMPP–federated chat service, or AIM, or ICQ, or MSN, or whatever you like, they all use the same address anyway) at the following address:
    [email protected]
    Edit: I should point out that it would be good form to post here if you're going to make a stab at it, so interested parties know how many people are already making attempts.
    Last edited by elliottcable (2009-07-25 03:59:46)

    drtoki wrote:
    http://blog.mudy.info/2009/04/archlinux-ec2-public-ami/
    lolwat
    from fryguy
    Public AMIs aren't what I need, because I need to mass–produce quite a few AMIs with different custom configurations for different purposes; so I have to be able to start from scratch and arrive at a working AMI *myself*.
    As for the script, I'm sitting down to play with it now; it looks just about exactly like what I've been doing so far. Maybe there's some small thing he did differently that will make it work. Here's hoping it works for me; that'll be a real load off my chest.

  • [SOLVED]Arch Linux running inside GNOME Boxes.

    Hello,
    I wanted to create a vm using GNOME Boxes to run another Arch Linux installation (to test things and avoid to break my main system).
    I did a normal install, then installed gnome-shell and gdm from testing repos. I enabled gdm and NetworkManager and after reboot my box.
    The box don't boot. The main display only see early fsck lines (about /), I can see in the thubnail more lines but can't read messages.
    What is wrong here ?
    Regards,
    Fabien
    Last edited by fbourigault (2014-10-07 11:22:36)

    I can't read it it only show in the thumbnail. I posted here to known if I missed some package installation or if someone already had the problem and solve it !.
    EDIT:
    I installed a new box, using gnome from stable repositories. I installed the same packages but didn't enable anything. I'm starting services by hand to allow me do configuration in the box
    You can find the gdm log here : http://pastebin.com/R5ek3Xwy (full version with multiple failing runs :http://pastebin.com/fCsPxAvb)
    EDIT 2 :
    Problem solved by installing xf86-video-qxl from AUR ! This package should really be in official repos.
    Last edited by fbourigault (2014-10-07 08:41:32)

  • Asus Transformer book T200TA

    Hello,
    I'm trying to put an Archlinux on the Asus Transformer book T200TA, and I will share here my progress. I will take note of a lot of things, when I manage to do something or when something does not work. And if you have any ideas to make something works, tell me !
    Current status (for TL;DR)
    - Boot under archiso : Working with patch
    - Boot Archlinux on the keyboard's HDD : Working by putting boot and efi partition on the internal memory
    - Virtualization of Windows 8.1 under linux : Partially working only with a 64 bit linux as host
    - SD card : Working with patch
    - Graphics : Working
    - Random freezes : Fixed ?. Didn't experienced any since my new installation with linux 4.0
    - xhci_hcd bug at boot ; Work in USB2 mode only
    - Backlight control : Working
    - Sound : Work on both headphone and speakers in stereo but you have to edit an alsa config file for enabling sound on one or both output and for setting the sound level. Microphone not tested.
    - Wifi : Not working
    - Bluetooth : Not working: Not working
    - Battery indicator : Working With kernell patch
    - Touchpad : Partially working : Only one finger and very unpleasant because the cursor move a little before you click.
    - Touchscreen : Partially working : Works randomly and seems to not release click when you remove your finger.
    Sources
    The T200TA has a lot on common with the T100TA, so, much of my fixes come from this computer (as it has been release one year before and the T200 is currently pretty new).
    - http://www.jfwhome.com/2014/03/07/perfe … book-t100/
    - https://github.com/AdamWill/baytrail-m
    - https://bbs.archlinux.org/viewtopic.php?id=179948
    Boot under archiso
    If you try to boot, it will not work. Because, as T100, it search only for 32bit efi (even if the cpu can handle 64bit OS). You can do like him.
    Or you can do like me, I think it's easier, but really dirty (it's not a full script, execute it only part by part) :
    ## Create working directory
    mkdir work
    cd work
    ## Build grub and get missing bootloader files bootia32.efi
    git clone git://git.savannah.gnu.org/grub.git
    cd grub
    ./autogen.sh
    export EFI_ARCH=i386
    ./configure --with-platform=efi --target=${EFI_ARCH} --program-prefix=""
    make
    cd grub-core
    ../grub-mkimage -d . -o bootia32.efi -O i386-efi -p /boot/grub ntfs hfs appleldr boot cat efi_gop efi_uga elf fat hfsplus iso9660 linux keylayouts memdisk minicmd part_apple ext2 extcmd xfs xnu part_bsd part_gpt search search_fs_file chain btrfs loadbios loadenv lvm minix minix2 reiserfs memrw mmap msdospart scsi loopback normal configfile gzio all_video efi_gop efi_uga gfxterm gettext echo boot chain eval
    cp bootia32.efi ../../bootia32.efi
    cd ../../
    rm -r grub
    ##Get all file from the current archlinux install iso
    #Search and replace all XXXX.XX.XX by the current release date and /dev/sdX by your usb key address. If you find a way to extract both partion from iso without dd, it should be faster than that, so tell me if you know how to do that.
    dd bs=4M if="archlinux-XXXX.XX.XX-dual.iso" of=/dev/sdX
    mkdir usb
    mkdir newiso
    # Unplug and replug your usb key and wait a little if mount doens't work :
    mount /dev/sdX2 ./usb
    cp -r usb/* newiso/
    sync
    umount usb
    mount /dev/sdX1 ./usb
    cp -r usb/* newiso/
    sync
    umount usb
    rmdir usb
    ## Prepare new usb key content
    mv bootia32.efi newiso/EFI/boot/
    mkdir -p newiso/boot/grub
    echo "
    menuentry 'Arch Linux i686'{
    echo 'Loading Linux core repo kernel ...'
    linux /arch/boot/i686/vmlinuz nomodeset archisobasedir=arch archisolabel=ARCHISO
    echo 'Loading initial ramdisk ...'
    initrd /arch/boot/i686/archiso.img
    menuentry 'Arch Linux x86_64'{
    echo 'Loading Linux core repo kernel ...'
    linux /arch/boot/x86_64/vmlinuz nomodeset archisobasedir=arch archisolabel=ARCHISO
    echo 'Loading initial ramdisk ...'
    initrd /arch/boot/x86_64/archiso.img
    }" > newiso/boot/grub/grub.cfg
    ## Prepare the usb key partition
    gdisk /dev/sdX
    3 # Create blank GPT
    o # Create a new empty GPT
    y # Proceed
    n # New partition
    # Default partition number
    # Default first sector
    # Default last sector
    EF00 # Bootable efi partition
    c # change partion's name
    ARCHISO
    w # Write modifications on the disk
    Y # Proceed
    mkfs.fat -F 32 /dev/sdX1
    echo mtools_skip_check=1 >> ~/.mtoolsrc
    mlabel -i /dev/sdX1 -s ::ARCHISO
    rm ~/.mtoolsrc
    ## Copy files to the usb key
    mkdir usb
    mount /dev/sdX1 usb
    cp -r newiso/* usb/
    sync
    umount usb
    rmdir usb
    ## Cleaning
    cd ../
    rm -r work
    A better way of fixing that should be building a x86 version of the file `PreLoader` from the repo `git://git.kernel.org/pub/scm/linux/kernel/git/jejb/efitools.git` because this file is renamed as `bootx64.efi` during the archiso creation, and the missing file is the x86 equivalent : `bootia32.efi`. Anyway, I didn't manage to build it, so I gave up this path. Tell me if you find something better.
    Boot Archlinux on the keyboard's HDD
    I cannot currently use this computer under linux for everyday, but I need a linux to work or dev. And I have to admit that the windows UI is much better for touchscreen than any linux desktop that I tried. The internal memory is only 30GB. So I let Windows 8.1 on internal memory for "tablet mode" and linux on hard drive for "netbook mode".
    I didn't find any way to make the computer boot to the hard drive (or the micro usb card of 64GB), the efi-bios don't see them (the HDD is pluged in usb 3.0, but even in USB 2.0 mode it does the same).
    To make it work, you have to put the boot and efi partition on the internal memory :
    - Create a boot parition (100mo ext2) on the internal memory or use the windows rescue partition (300mo, ntfs, ~86%used after grub and vmlinuz installation). And during your installation process, mount it at /boot (/dev/mmcblkpX)
    - Use the windows EFI parition (100mo fat32) and mount it to /boot/efi (/dev/mmcblkpY)
    - Then (re-)install linux (need internet connexion, wireless or no. Dont forget to start dhcpcd)
    mount /dev/sdbZ /mnt # with /dev/sdbZ your keyboard's hdd root partition where linux will be installed
    mkdir /mnt/boot
    mount /dev/mmcblkpX /mnt/boot
    mkdir /mnt/boot/efi
    mount /dev/mmcblkpY /mnt/boot/efi
    pacstrap /mnt/ base grub efibootmgr
    genfstab -U -p /mnt >> /mnt/etc/fstab
    - and install grub on partition
    arch-chroot /mnt
    grub-install --target=i386-efi --efi-directory=/boot/efi --bootloader-id=grub --recheck
    - Edit /etc/grub.d/40_custom and add at the end :
    if [ "${grub_platform}" == "efi" ]; then
    menuentry "Microsoft Windows Vista/7/8/8.1 UEFI-GPT" {
    insmod part_gpt
    insmod fat
    insmod search_fs_uuid
    insmod chain
    search --fs-uuid --set=root --hint-bios=hd0,gptY --hint-efi=hd0,gptY --hint-baremetal=ahci0,gptY [fs_uuid]
    chainloader /EFI/Microsoft/Boot/bootmgfw.efi
    fi
    with gptY, the Y from /dev/mmcblkpY above (the efi partition)
    and [hints_string] is gave by the command
    grub-probe --target=fs_uuid /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi
    - Apply grub config
    grub-mkconfig -o /boot/grub/grub.cfg
    Now I can boot to "Windows Boot Manager" or "grub" from bios. But I choosed to have grub by default and then he ask me what I want.
    Virtualization
    What works :
    - host Win32, guest linux32
    - host win32, guest win32
    - host linux32, guest linux32
    - host linux64, guest win
    What doesn't work:
    - host linux32, guest win32
    Windows 8.1 guest : With QEMU and Virtualbox, same problem during installation (or boot when already installed) we got a
    Your PC needs to restart.
    Please hold down the power button.
    Error Code: 0x0000000A
    Parameters:
    0xFFFFFFE6
    0x0000001F
    0x00000000
    0x8192BFAB
    After 3min virtualbox said that a critical error happend and tell us to watch the log. But it seem useless because the bug happend after 7 seconds and nothing show up after 7 seconds.
    SD Card
    http://www.jfwhome.com/2014/03/07/perfect-ubuntu-or-other-linux-on-the-asus-transformer-book-t100/ wrote:
    The SD card reader works with newer kernels, but the sdhci module needs some configuration. Create a new file:
    sudo nano /etc/modprobe.d/sdhci.conf
    Then add the following:
    options sdhci debug_quirks=0x8000
    ctrl-o then ctrl-x to save and exit, then:
    sudo mkinitcpio -p linux
    Graphics
    2D and 3D accelerations are enabled with xf86-video-intel 2.99.917 and mesa 10.4 :
    $ glxinfo | grep direct :(
    direct rendering: Yes
    GL_ARB_draw_elements_base_vertex, GL_ARB_draw_indirect,
    GL_ARB_map_buffer_range, GL_ARB_multi_bind, GL_ARB_multi_draw_indirect,
    $ glxinfo | grep OpenGL
    OpenGL vendor string: Intel Open Source Technology Center
    OpenGL renderer string: Mesa DRI Intel(R) Bay Trail x86/MMX/SSE2
    OpenGL core profile version string: 3.3 (Core Profile) Mesa 10.4.0
    OpenGL core profile shading language version string: 3.30
    OpenGL core profile context flags: (none)
    OpenGL core profile profile mask: core profile
    OpenGL core profile extensions:
    OpenGL version string: 3.0 Mesa 10.4.0
    OpenGL shading language version string: 1.30
    OpenGL context flags: (none)
    OpenGL extensions:
    OpenGL ES profile version string: OpenGL ES 3.0 Mesa 10.4.0
    OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.0
    OpenGL ES profile extensions:
    However firefox doens't enable 3D acceleration by default, you have to force it. To check if it use it, go to about:support
    And this mean that, it doesn't support it :
    GPU Accelerated Windows 0/1 Basic
    To force it :
    - Got to about:config
    - Set layers.acceleration.force-enabled
    - Set layers.offmainthreadcomposition.enabled to true
    And restart firefox. Now you should have
    GPU Accelerated Windows 1/1 OpenGL (OMTC)
    Warning : 3D acceleration can make firefox more buggy, so try to disable it if you have problems.
    source : http://askubuntu.com/questions/491750/f … in-firefox
    Random freezes
    After some minutes (last time after ~40minutes) the system freeze. I don't know if it's only graphical or not. This freeze seem to happend when the cpu/gpu has a lot to do.
    I've done a clean install with default kernel 4.0 in may 2015, and since that, I didn't have any freeze.
    xhci_hcd bug at boot
    When I enable XHCI in bios, sometime, I get that
    xhci_hcd 0000:00:14.0: Error while assigning device slot ID
    xhci_hcd 0000:00:14.0: Max number of devices this xHCI host supports is 32.
    usb usb1-port3: couldn't allocate usb_device
    The port change randomly and when it is port3, I loose the keybard and mouse and I have to make a hard reebot.
    To "fix" this, I disabled XHCI (wich mean USB3) from the bios.
    Still happen with kernel 4.0
    Sound
    With the work of  sid789. I manage to make sound work on Linux 4.0.
    Save this file somewhere on your computer : asound.state
    state.bytrt5640 {
    #### General
    # Level
    control.1 {
    iface MIXER
    name 'DAC1 Playback Volume'
    value.0 175 # Left volume
    value.1 175 # right volume
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 175'
    dbmin -65625
    dbmax 0
    dbvalue.0 0
    dbvalue.1 0
    # Disable both output Right
    control.51 {
    iface MIXER
    name 'Stereo DAC MIXR DAC R1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable both Left speaker
    control.54 {
    iface MIXER
    name 'Stereo DAC MIXL DAC L1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Channel to listen
    control.21 {
    iface MIXER
    name 'DAC IF1 Data Switch'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 Normal
    item.1 Swap
    item.2 'left copy to right'
    item.3 'right copy to left'
    # Enable
    # Only 0 and 2 works
    control.100 {
    iface MIXER
    name 'DAI select'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 '1:1|2:2'
    item.1 '1:2|2:1'
    item.2 '1:1|2:1'
    item.3 '1:2|2:2'
    ##### Speaker #####
    #Enable
    control.27 {
    iface MIXER
    name 'Speaker Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    #Change a little the volume..
    control.19 {
    iface MIXER
    name 'Class D SPK Ratio Control'
    value 10
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 '1.66x'
    item.1 '1.83x'
    item.2 '1.94x'
    item.3 '2x'
    item.4 '2.11x'
    item.5 '2.22x'
    item.6 '2.33x'
    item.7 '2.44x'
    item.8 '2.55x'
    item.9 '2.66x'
    item.10 '2.77x'
    # Enable Left speaker
    control.62 {
    iface MIXER
    name 'Speaker L Playback Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable right speaker
    control.61 {
    iface MIXER
    name 'Speaker R Playback Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable right channel on right speaker
    control.67 {
    iface MIXER
    name 'SPOR MIX DAC R1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable right channel on left speaker
    control.70 {
    iface MIXER
    name 'SPOL MIX DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable left channel
    control.71 {
    iface MIXER
    name 'SPOL MIX DAC L1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    ##### headphone #####
    # Enable
    control.24 {
    iface MIXER
    name 'Headphone Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    #Enable too
    control.34 {
    iface MIXER
    name 'HPO MIX DAC1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable Left
    control.98 {
    iface MIXER
    name 'DAC MIXL INF1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable Right
    control.96 {
    iface MIXER
    name 'DAC MIXR INF1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable right
    control.59 {
    iface MIXER
    name 'HP R Playback Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Enable Left
    control.60 {
    iface MIXER
    name 'HP L Playback Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # Don't know what, but change something on headphone
    control.58 {
    iface MIXER
    name 'DAC L2 Mux'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 IF2
    item.1 'Base L/R'
    ## Useless on output
    control.2 {
    iface MIXER
    name 'Mono Playback Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.11 {
    iface MIXER
    name 'Mono DAC Playback Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 175'
    dbmin -65625
    dbmax 0
    dbvalue.0 -1500
    dbvalue.1 -1500
    control.3 {
    iface MIXER
    name 'Speaker Channel Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.4 {
    iface MIXER
    name 'Speaker Playback Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 39'
    dbmin -4650
    dbmax 1200
    dbvalue.0 -900
    dbvalue.1 -900
    control.5 {
    iface MIXER
    name 'HP Channel Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.6 {
    iface MIXER
    name 'HP Playback Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 39'
    dbmin -4650
    dbmax 1200
    dbvalue.0 1200
    dbvalue.1 1200
    control.7 {
    iface MIXER
    name 'OUT Playback Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.8 {
    iface MIXER
    name 'OUT Channel Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.9 {
    iface MIXER
    name 'OUT Playback Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 39'
    dbmin -4650
    dbmax 1200
    dbvalue.0 -1950
    dbvalue.1 -1950
    control.10 {
    iface MIXER
    name 'DAC2 Playback Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.12 {
    iface MIXER
    name 'IN1 Boost'
    value 8
    comment {
    access 'read write'
    type INTEGER
    count 1
    range '0 - 8'
    dbmin 0
    dbmax 5200
    dbvalue.0 3000
    control.13 {
    iface MIXER
    name 'IN2 Boost'
    value 8
    comment {
    access 'read write'
    type INTEGER
    count 1
    range '0 - 8'
    dbmin 0
    dbmax 5200
    dbvalue.0 3500
    control.14 {
    iface MIXER
    name 'IN Capture Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 31'
    dbmin -3450
    dbmax 1200
    dbvalue.0 -300
    dbvalue.1 -300
    control.15 {
    iface MIXER
    name 'ADC Capture Switch'
    value.0 false
    value.1 false
    comment {
    access 'read write'
    type BOOLEAN
    count 2
    control.16 {
    iface MIXER
    name 'ADC Capture Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 127'
    dbmin -17625
    dbmax 30000
    dbvalue.0 28500
    dbvalue.1 28500
    control.17 {
    iface MIXER
    name 'Mono ADC Capture Volume'
    value.0 0
    value.1 0
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 127'
    dbmin -17625
    dbmax 30000
    dbvalue.0 27000
    dbvalue.1 27000
    control.18 {
    iface MIXER
    name 'ADC Boost Gain'
    value.0 3
    value.1 3
    comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 3'
    dbmin 0
    dbmax 3600
    dbvalue.0 1200
    dbvalue.1 1200
    control.20 {
    iface MIXER
    name 'ADC IF1 Data Switch'
    value 1
    comment {
    access 'read write'
    type ENUMERATED
    count 3
    item.0 Normal
    item.1 'left copy to right'
    item.2 'right copy to left'
    item.3 Swap
    control.22 {
    iface MIXER
    name 'ADC IF2 Data Switch'
    value 3
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 Normal
    item.1 'left copy to right'
    item.2 'right copy to left'
    item.3 Swap
    control.23 {
    iface MIXER
    name 'DAC IF2 Data Switch'
    value 1
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 Normal
    item.1 'left copy to right'
    item.2 'right copy to left'
    item.3 Swap
    control.25 {
    iface MIXER
    name 'Headset Mic Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.26 {
    iface MIXER
    name 'Internal Mic Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.28 {
    iface MIXER
    name 'Mono MIX DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.29 {
    iface MIXER
    name 'Mono MIX DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.30 {
    iface MIXER
    name 'Mono MIX OUTVOL R Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.31 {
    iface MIXER
    name 'Mono MIX OUTVOL L Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.32 {
    iface MIXER
    name 'Mono MIX BST1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.33 {
    iface MIXER
    name 'HPO MIX DAC2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.35 {
    iface MIXER
    name 'HPO MIX HPVOL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.36 {
    iface MIXER
    name 'OUT MIXR SPK MIXR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.37 {
    iface MIXER
    name 'OUT MIXR BST2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.38 {
    iface MIXER
    name 'OUT MIXR BST1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.39 {
    iface MIXER
    name 'OUT MIXR INR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.40 {
    iface MIXER
    name 'OUT MIXR REC MIXR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.41 {
    iface MIXER
    name 'OUT MIXR DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.42 {
    iface MIXER
    name 'OUT MIXR DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.43 {
    iface MIXER
    name 'OUT MIXR DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.44 {
    iface MIXER
    name 'OUT MIXL SPK MIXL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.45 {
    iface MIXER
    name 'OUT MIXL BST1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.46 {
    iface MIXER
    name 'OUT MIXL INL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.47 {
    iface MIXER
    name 'OUT MIXL REC MIXL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.48 {
    iface MIXER
    name 'OUT MIXL DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.49 {
    iface MIXER
    name 'OUT MIXL DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.50 {
    iface MIXER
    name 'OUT MIXL DAC L1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.52 {
    iface MIXER
    name 'Stereo DAC MIXR DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.53 {
    iface MIXER
    name 'Stereo DAC MIXR ANC Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.55 {
    iface MIXER
    name 'Stereo DAC MIXL DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.56 {
    iface MIXER
    name 'Stereo DAC MIXL ANC Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.57 {
    iface MIXER
    name 'DAC R2 Mux'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 IF2
    control.63 {
    iface MIXER
    name 'LOUT MIX DAC L1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.64 {
    iface MIXER
    name 'LOUT MIX DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.65 {
    iface MIXER
    name 'LOUT MIX OUTVOL L Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.66 {
    iface MIXER
    name 'LOUT MIX OUTVOL R Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.68 {
    iface MIXER
    name 'SPOR MIX SPKVOL R Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.69 {
    iface MIXER
    name 'SPOR MIX BST1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.72 {
    iface MIXER
    name 'SPOL MIX SPKVOL R Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.73 {
    iface MIXER
    name 'SPOL MIX SPKVOL L Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.74 {
    iface MIXER
    name 'SPOL MIX BST1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.75 {
    iface MIXER
    name 'SPK MIXR REC MIXR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.76 {
    iface MIXER
    name 'SPK MIXR INR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.77 {
    iface MIXER
    name 'SPK MIXR DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.78 {
    iface MIXER
    name 'SPK MIXR DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.79 {
    iface MIXER
    name 'SPK MIXR OUT MIXR Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.80 {
    iface MIXER
    name 'SPK MIXL REC MIXL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.81 {
    iface MIXER
    name 'SPK MIXL INL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.82 {
    iface MIXER
    name 'SPK MIXL DAC L1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.83 {
    iface MIXER
    name 'SPK MIXL DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.84 {
    iface MIXER
    name 'SPK MIXL OUT MIXL Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.85 {
    iface MIXER
    name 'DIG MIXR DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.86 {
    iface MIXER
    name 'DIG MIXR DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.87 {
    iface MIXER
    name 'DIG MIXL DAC L1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.88 {
    iface MIXER
    name 'DIG MIXL DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.89 {
    iface MIXER
    name 'Mono DAC MIXR DAC R1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.90 {
    iface MIXER
    name 'Mono DAC MIXR DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.91 {
    iface MIXER
    name 'Mono DAC MIXR DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.92 {
    iface MIXER
    name 'Mono DAC MIXL DAC L1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.93 {
    iface MIXER
    name 'Mono DAC MIXL DAC L2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.94 {
    iface MIXER
    name 'Mono DAC MIXL DAC R2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.95 {
    iface MIXER
    name 'DAC MIXR Stereo ADC Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.97 {
    iface MIXER
    name 'DAC MIXL Stereo ADC Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.99 {
    iface MIXER
    name 'SDI select'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 IF1
    item.1 IF2
    control.101 {
    iface MIXER
    name 'Mono ADC MIXR ADC1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.102 {
    iface MIXER
    name 'Mono ADC MIXR ADC2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.103 {
    iface MIXER
    name 'Mono ADC MIXL ADC1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.104 {
    iface MIXER
    name 'Mono ADC MIXL ADC2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.105 {
    iface MIXER
    name 'Stereo ADC MIXR ADC1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.106 {
    iface MIXER
    name 'Stereo ADC MIXR ADC2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.107 {
    iface MIXER
    name 'Stereo ADC MIXL ADC1 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.108 {
    iface MIXER
    name 'Stereo ADC MIXL ADC2 Switch'
    value false
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.109 {
    iface MIXER
    name 'Mono ADC R2 Mux'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 'DMIC R1'
    item.1 'DMIC R2'
    item.2 'Mono DAC MIXR'
    control.110 {
    iface MIXER
    name 'Mono ADC R1 Mux'
    value 'Mono DAC MIXR'
    comment {
    access 'read write'
    type ENUMERATED
    count 0
    item.0 'Mono DAC MIXR'
    item.1 ADCR
    control.111 {
    iface MIXER
    name 'Mono ADC L1 Mux'
    value 1
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 'Mono DAC MIXL'
    item.1 ADCL
    control.112 {
    iface MIXER
    name 'Mono ADC L2 Mux'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 'DMIC L1'
    item.1 'DMIC L2'
    item.2 'Mono DAC MIXL'
    control.114 {
    iface MIXER
    name 'Stereo ADC2 Mux'
    value 0
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 DMIC1
    item.1 DMIC2
    item.2 'DIG MIX'
    control.115 {
    iface MIXER
    name 'RECMIXR HPOR Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.116 {
    iface MIXER
    name 'RECMIXR INR Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.117 {
    iface MIXER
    name 'RECMIXR BST2 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.118 {
    iface MIXER
    name 'RECMIXR BST1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.119 {
    iface MIXER
    name 'RECMIXR OUT MIXR Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.120 {
    iface MIXER
    name 'RECMIXL HPOL Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.121 {
    iface MIXER
    name 'RECMIXL INL Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.122 {
    iface MIXER
    name 'RECMIXL BST2 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.123 {
    iface MIXER
    name 'RECMIXL BST1 Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    control.124 {
    iface MIXER
    name 'RECMIXL OUT MIXL Switch'
    value true
    comment {
    access 'read write'
    type BOOLEAN
    count 1
    # WARNING
    # !!WARN!! BUZZ ANS BREAK EVERYTHING UNTIL REBOOT !!!!!!!
    control.113 {
    iface MIXER
    name 'Stereo ADC1 Mux'
    value 1
    comment {
    access 'read write'
    type ENUMERATED
    count 1
    item.0 'DIG MIX'
    item.1 ADC
    and you can load it by doing
    alsactl -f asound.state restore
    To change the values, you have to edit the field "value" of a control and reload the config file with the precedent command. I tried to comment it, but I didn't test any microphone, because I didn't need it currently. We are supposed to have 2 microphones : internal and via the jack. I think it's possible, but I don't have any jack microphone, so if you need it, try to change the different settings and tell me if you find something.
    I don't think any GUI, will manage to make the sound control work (even in alsamixer, it's a big mess), because there is no convention followed.
    To be continued
    Last edited by Ziqumu (2015-05-30 20:06:48)

    I had still freeze with uxa. I still don't have any freeze with disabled acceleration. But I also have the flickering tty, but it's not a big problem as this is still usable and I don't often use it.
    Maybe when you tried, it was another bug that makes you freeze (with an older version of someting).. I don't know, I will write both solution on the topic.
    I've done some search on the touchpad : If you look at the device output (cat /dev/hidraw2 for me), you will see that the device don't send anything when you have two finger that touch the device (so it's not possible to use it as dualtouch). I think it's just a starting data that is send from Asus Smart Gesture under windows that start the Multi touch mode. I've start a vritual machine and I gave it the touchpad usb device (wich is also the keyboard... Usb bus 1 address 3) and I started the driver. Under windows it worked well with multitouch. I killed the virtual machine and I got back my keyboard but not the touchpad. I watch at /dev/hidraw2 and the touchpad now give information with two and more fingers (also it give immediatly data and not after a small lag like normally). After a restart it was gone as expected. I watched the usb driver with usbmon and wireshark and I tried to reproduce UsbHid exchange between computer and device but it didn't work. I still don't know why but I will continue to search.
    There is 3 sub device on the usb device mouse/keyboard. 0 is the keyboard, 1 the media key (fn keys except sound) from the keyboard, and 2 the touchpad. So if someone has time to works on media keys, I don't think this is verry difficult. (It's more difficult for the sound, win and sleep button on the screeen, because I didn't find any signals from it.
    I will try to work on a aur package that give our kernel with fixes this summer. (And maybe also a pre-builded version).
    Last edited by Ziqumu (2015-06-04 23:15:27)

  • [Solved] Please help setting up xbmc on Arch Linux

    Trying to setup Arch Linux on my Asus Chromebox to run XBMC at startup. I have installed the following packages as per a guide on another site, xorg-server xorg-xinit xf86-video-intel xbmc. Whan I try to manually start xbmc, it gives me
    Error: unable to open display
    XBMC needs hardware accelerated OpenGL rendering.
    Install an appropriate graphics driver.
    Please consult XBMC Wiki for supported hardware
    [url=http://wiki.xbmc.org/?title=Supported_hardware]http://wiki.xbmc.org/?title=Supported_hardware"[/url]
    When I try startx, I get the following
    X.Org X Server 1.16.2
    Release Date: 2014-11-10
    X Protocol Version 11, Revision 0
    Build Operating System: Linux 3.17.2-1-ARCH x86_64
    Current Operating System: Linux bunga 3.17.4-1-ARCH #1 SMP PREEMPT Fri Nov 21 21:14:42 CET 2014 x86_64
    Kernel command line: BOOT_IMAGE=/boot/vmlinuz-linux root=UUID=c20ca43d-7d5a-4335-bca3-a0224f2280c3 rw quiet
    Build Date: 10 November 2014 07:52:13PM
    Current version of pixman: 0.32.6
    Before reporting problems, check [url]http://wiki.x.org[/url]
    to make sure that you have the latest version.
    Markers: (--) probed, (**) from config file, (==) default setting,
    (++) from command line, (!!) notice, (II) informational,
    (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
    (==) Log file: "/var/log/Xorg.0.log", Time: Mon Dec 8 23:23:00 2014
    (==) Using system config directory "/usr/share/X11/xorg.conf.d"
    /etc/X11/xinit/xinitrc: line 51: twm: command not found
    /etc/X11/xinit/xinitrc: line 53: xterm: command not found
    /etc/X11/xinit/xinitrc: line 54: xterm: command not found
    /etc/X11/xinit/xinitrc: line 55: exec: xterm: not found
    xinit: connection to X server lost
    waiting for X server to shut down (EE) Server terminated successfully (0). Closing log file.
    That's as far as I've been able to get, what else do I need to do?
    Thanks for any help!
    Last edited by regder (2014-12-13 03:49:29)

    Thank you, wasn't sure how to interpret X's output. I'm just trying to start xbmc from the command line, haven't tried yet getting it to autostart. Is there another command I should be using so it invokes X?
    jasonwryan wrote:
    Well, the error message is pretty clear: X is starting successfully, there is just nothing for it to do.
    What method are you using to start xbmc? https://wiki.archlinux.org/index.php/Xb … r_ondemand

  • Arch Linux on Intel Macs?

    Are there any plans to make Arch Linux run on the new Intel based Macs?

    BTW, talking to an Apple salesman over the weekend. Apparently the new iMacs will run Windows Vista too! Unlike previous Macs, they are not using a proprietary Apple BIOS setup, but something more general purpose that is compatible with Vista too. Apple doesn't want you running MacOS on your PC, but they don't seem to mind you running Windows on your Mac. Lets them get into the booming PC hardware business! The salesman assured me that most Linux distros would be able to run on the machines.
    I played around with them, and despite having on 2 GHz chips (but two of them, of course) the iMacs were very responsive. I can only guess that MacOS is lighter than Windows, and hence faster subjectively on these "slower" processors.

  • USB on Arch Linux as guest in virtualbox

    Hi. I'm trying to access the usb port in the arch linux running as guest in the virtualbox so I added in the "/etc/fstab" file this line:
    "none /proc/bus/usb usbfs auto,busgid=###,busmode=0775,devgid=108,devmode=0664 0 0"
    to mount the usb automatically, where "###" is the group id that the user is in. As i wasn't in any group and 'vboxusers' group wasn't created when I installed "virtualbox-guest-utils" as I expected so I created the group and added my self into it doing:
    sudo groupadd vboxusers
    sudo usermod -aG vboxusers rsegecin
    grep vboxusers /etc/group
    after that when I tried to mount all devices using "mount -a" I get an error saying that the mounting point  "/proc/bus/usb" doesn't exist, so I created another mount point in "/home/rsegecin/usb" and I got another error saying that the file system type 'usbfs' is unknown.
    how do I register the file system type 'usbfs'? how can I access the usb port in guest arch linux?
    thank you very much.

    Okay, this is a long shot.  Let's try this experiment.  I found a suggest that one try this as root:
    mount --bind /dev/bus/usb /proc/bus/usb
    But here is what that does.  In the olden days, /proc was the way to deal with virtual file systems that let you communicate with the kernel.  It used to be there was /proc/bus/usb.  That was deprecated, and later removed in favor of /dev/bus/usb.  It kind of makes sense, because it is a device, not a kernel thingy.  But there are legacy software that look in /proc/bus.  That bind command links the old method to the new method.  But, it also says that the stuff in /dev/bus/usb is the same stuff that had been in /proc/bus/usb.  (Forgive we, I am thinking this though as I type).   Where this leaves me is this, your device is appearing at /dev/bus/usb/001/002.  You can prove that by removing the device (using the Virtualbox tools to disconnect the device from the VM).  That node should go away, then reappear when you reconnect it.  The problem is what do you do with it?  I don't think that usbfs exists anymore.
    What kind of device is it?  There may be a better way to deal with it.  Obviously, if it is mass storage, there are ways to use it as such.  Likewise, if it is a character device (serial port, modem, etc) there may be a /dev/ttyUSBx type node to talk to it.  If it is a HID (Human Interface Device) like a keyboard, mouse, joystick. or a lot of widgets that use the HID model (like credit card readers), there will be a node like /dev/hidraw0.  I have used that quite a bit.
    Maybe we should back up a bit.  After you (virtually) connect the device, what gets appended to the journal?  Also, what is the output of lsusb -v

  • Benchmarking or a "resources reducer" to use on arch linux

    Helo pals....
    Let me explain what I want.
    I'm a folding at home entusiast, and, at this moment, I'm working with graysky's -ck kernel, liquorix kernel, trying to work with ice and pf ones (headers don't compiles with) and kernel rt
    In a second time, the same kernels with NUMA, actually set to "off"
    But, I'm looking for a resources reducer, or a benchmarking program that I could make "a load" on the system.
    When I put to fold with a kernel, actually, I do it in idle, on normal using, and with "heavy processing", but I've some issues during heavy load:
    I do it making some 20gb TAR files, using ark, but, when the files ends, it come back to idle... and, 20Gb uses more or less 20 minutes. 20 minutes is not enough to have a good idea about it.
    I thought about compiling something during the folding, but it's not good too, cause if I receive some error during compiling, the system starts in a annoying mode (don't open something, or crash some applications) and I should restart
    and, even compiling gives a "non linear" load...
    I need to give the system a load about 30%, and/or 20 to 60% to do "real loading tests" could you help me?
    arch linux running under 965BE, motherboard gigabyte 970A-D3, 12Gb RAM (2+2 4+4) with water cooler (antec kuhler 620A with 2 fans) and zogis 650Ti
    PSU twice corsair VX550W

    community/stress 1.0.4-3
        A tool that stress tests your system (CPU, memory, I/O, disks)
    community/cpuburn 1.4a-3
        CPU testing utilities in optimized assembler for maximum loading of CPUs

  • [SOLVED] Arch Linux install on UEFI motherboard (Asus UX31A)

    Hello all,
    I am new to Arch Linux (moving over from Mint) and I am having an enormous amount of trouble with booting for UEFI.  I go through all the command line installation steps and get to the step where you install and configure a bootloader.  I have followed everything step-by-step up and cannot seem to get anything to boot, I get the motherboard settings menu instead.  I've tried GRUB, rEFInd, and Gummiboot and all three have not worked for me.  Is there any hope for configuring a bootloader?  I am used to Mint/Ubuntu creating it for me.
    Thanks
    Last edited by somedood (2013-06-09 13:23:51)

    srs5694 wrote:It shouldn't matter from where you launch the EFI shell, although that will affect device names. If you boot a USB flash drive with an EFI shell on it, chances are fs0: will be the USB flash drive itself. Your rEFInd, though, should be installed on your hard disk, and therefore on another device -- probably fs1:, although it could be fs2:, fs3:, or some other number. If the only filesystem you can find is fs0:, then that indicates something is wrong with your hard disk setup -- perhaps your ESP's filesystem is damaged, or maybe there's something wrong with the partition table.
    I followed the steps in the beginners installation guide to create my file system starting with:
    cgdisk /dev/sda1
    I create 4 Linux filesystem partitions with this, then I run:
    mkfs.vfat -32 /dev/sda1
    mkfs.ext4 /dev/sda2
    mkfs.ex4 /dev/sda3
    mkswap /dev/sda4
    I then toggle the boot flag of my FAT32 formatted ESP (/dev/sda1):
    parted
    toggle
    1
    boot
    if it is not turned on according to the output of:
    parted
    print
    After that I mount the drives and turn swap on:
    mount /dev/sda2 /mnt
    mkdir -p /mnt/home
    mount /dev/sda3 /mnt/home
    mkdir -p /mnt/boot/efi
    mount /dev/sda1 /mnt/boot/efi
    swapon /dev/sda4
    I install my base system (without changing /etc/pacman.d/mirrorlist) by running:
    pacstrap -i /mnt base
    Finally I generate my fstab after the Arch installation:
    genfstab -U -p /mnt >> /mnt/etc/fstab
    I then check the fstab and I get the result from my previous post and according to the guide it is ok because everything but my root partition has a 0 or 2.
    somedood wrote:# /dev/sda2
    UUID=264fe719-b816-462d-af5b-1b76c73a875b     /     ext4     rw,relatime,data=ordered     0     1
    # /dev/sda3
    UUID=824c5b36-6bf3-4c66-8878-5c886dadc9dd     /home     ext4     rw,relatime,data=ordered     0     2
    # /dev/sda1
    UUID=49B1-AE7E     /boot/efi     vfat     rw,relatime,fmask=0022, dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro     0     2
    # /dev/sda4
    UUID=426143bf-0cb4-4b7e-8868-e82d6fe7bd8b     none     swap     defaults     0     0
    To clarify, sda2 and sda3 are my root and home partitions respectively, sda4 is my swap, and sda1 is my ESP.
    What could have gone wrong here?  This is quite frustrating to me and I really want to use Arch.

  • [SOLVED]Multiple Problems after a new install on Arch Linux

    Hello all,
    I just finished installing Arch Linux from the core ISO which I downloaded from the site. The install went smoothly and booted up fine. Also I was able to install gnome and its extras fine as well. On the first boot after installing gnome I managed to get my resolution correct also. However later on after I installed compiz fusion everything with the resolution seems to be going wrong . My computer specs are shown below :
    AMD 64 3200
    Asus M2N MX-SE
    2 GB Ram
    Geforce 8600 GT
    Viewsonic VA1918wm (Native resolution is 1440x900)
    At the moment I can only manage to get upto 1024x768 and it looks quite bad at that resolution. I have attached the xorg.conf I have at the moment.
    Section "ServerLayout"
    Identifier "X.org Configured"
    Screen 0 "Screen0" 0 0
    InputDevice "Mouse0" "CorePointer"
    InputDevice "Keyboard0" "CoreKeyboard"
    EndSection
    Section "Files"
    ModulePath "/usr/lib/xorg/modules"
    FontPath "/usr/share/fonts/misc"
    FontPath "/usr/share/fonts/100dpi:unscaled"
    FontPath "/usr/share/fonts/75dpi:unscaled"
    FontPath "/usr/share/fonts/TTF"
    FontPath "/usr/share/fonts/Type1"
    EndSection
    Section "Module"
    Load "dbe"
    Load "record"
    Load "extmod"
    Load "glx"
    Load "dri2"
    Load "dri"
    EndSection
    Section "InputDevice"
    Identifier "Keyboard0"
    Driver "kbd"
    EndSection
    Section "InputDevice"
    Identifier "Mouse0"
    Driver "mouse"
    Option "Protocol" "auto"
    Option "Device" "/dev/input/mice"
    Option "ZAxisMapping" "4 5 6 7"
    EndSection
    Section "Monitor"
    Identifier "Monitor0"
    VendorName "Monitor Vendor"
    ModelName "Monitor Model"
    EndSection
    Section "Device"
    Identifier "Card0"
    Driver "nvidia"
    VendorName "nVidia Corporation"
    BoardName "G84 [GeForce 8600 GT]"
    BusID "PCI:2:0:0"
    EndSection
    Section "Screen"
    Identifier "Screen0"
    Device "Card0"
    Monitor "Monitor0"
    SubSection "Display"
    Viewport 0 0
    Depth 1
    EndSubSection
    SubSection "Display"
    Viewport 0 0
    Depth 4
    EndSubSection
    SubSection "Display"
    Viewport 0 0
    Depth 8
    EndSubSection
    SubSection "Display"
    Viewport 0 0
    Depth 15
    EndSubSection
    SubSection "Display"
    Viewport 0 0
    Depth 16
    EndSubSection
    SubSection "Display"
    Viewport 0 0
    Depth 24
    EndSubSection
    EndSection
    While I was trying to fix this I noticed I was encountering other problems also. For one I found that sometimes dhcpcd times out on booting up and I cant seemt o connect to the Internet on booting. Although I just thought of trying a static IP and I'll post if that helped later on.
    Another problem is I found that I seem to get the following error randomly. Pressing ctrl + D after this just restarts the machine.
    The superblock could not be read or does not describe a correct ext2
    filesystem. If the device is valid and it really contains an ext2
    filesystem (and not swap or ufs or something else), then the superblock
    is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>
    Finally, while I boot up I noticed that it says "Mounting root partition as read only   [DONE]"  Is the root partition supposed ot be mounted as read only ? Attached my fstab just in case it is needed.
    # /etc/fstab: static file system information
    # <file system> <dir> <type> <options> <dump> <pass>
    none /dev/pts devpts defaults 0 0
    none /dev/shm tmpfs defaults 0 0
    #/dev/cdrom /media/cd auto ro,user,noauto,unhide 0 0
    #/dev/dvd /media/dvd auto ro,user,noauto,unhide 0 0
    #/dev/fd0 /media/fl auto user,noauto 0 0
    /dev/sda3 /boot ext3 defaults 0 1
    /dev/sdb1 / ext3 defaults 0 1
    /dev/sdb2 swap swap defaults 0 0
    /dev/sdb3 /home ext3 defaults 0 1
    As you can see I'm quite new to Arch Linux so any help would be deeply appreciated.
    Last edited by FilledVoid (2009-09-11 16:28:28)

    Thank you for all your suggestions . I tried replacing the ID to Card0 but it didnt seem to fix it . However on the bright side I checked more threads on the forum and found some that helped out . :)
    http://bbs.archlinux.org/viewtopic.php?id=75070&p=2
    http://bbs.archlinux.org/viewtopic.php?id=72788
    http://bbs.archlinux.org/viewtopic.php?id=76938
    I copied the xorg.conf file from the third link and just made minor changes to it like removing all the resolutions I didn't need and now its working fine :).
    Now Im just stuck with two problems. One is the following message which appears randomly.
    The superblock could not be read or does not describe a correct ext2
    filesystem. If the device is valid and it really contains an ext2
    filesystem (and not swap or ufs or something else), then the superblock
    is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>
    ******************* FILESYSTEM CHECK FAILED *************
    * Please repair manually and reboot. Note that the root *
    * filesystem is currently mounted read-only. To remount *
    * it read-write type: mount -n -o remount,rw / *
    * When you exit the mantenance shel the system will *
    * reboot automatically. *
    A thread about the same can be found http://bbs.archlinux.org/viewtopic.php?pid=295384 but there isn't a solution on it. 
    The second is the intermittent problems with the Network being setup. Sometimes when I boot up it just says dhcpcd timedout and I won't be able to connect . However I can connect on another machine at the same time.
    Took a look at the drive in question with gparted and it shows the below information:
    /dev/sdb1 ext3   /   32.59 GB    4.92 GB   27.68 GB  boot
    By any chance is any of the above information relevant :x ?

  • Recovering earlier installed Windows 7 after installing Arch Linux

    I'm trying to boot windows on my ASUS notebook.
    There was windows 7 from the very beginning (disks C:\ and D:\), then I divided disk D:\ on several partitions and installed Arch Linux. I overwrited Windows boot information by boot part of Linux. Now I want to recover windows, that I still have on hard drive. It doesn's matter what there will be: dualboot or only windows (but dualboot is prefered).
    Disk info:
    [jhon@fckrsns ~]$ sudo fdisk -l
    Disk /dev/sda: 698.7 GiB, 750156374016 bytes, 1465149168 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 4096 bytes
    I/O size (minimum/optimal): 4096 bytes / 4096 bytes
    Disklabel type: gpt
    Disk identifier: 1AFC9DFF-CD3B-4CE1-8CAF-41C3E5B75772
    Device Start End Size Type
    /dev/sda1 2048 411647 200M EFI System
    /dev/sda2 411648 673791 128M Microsoft reserved
    /dev/sda3 673792 586731519 279.5G Microsoft basic data
    /dev/sda4 586731520 691589119 50G Linux filesystem
    /dev/sda5 1412718592 1465147391 25G Windows recovery environment
    /dev/sda6 691589120 901304319 100G Linux filesystem
    /dev/sda7 901304320 1412718591 243.9G Microsoft basic data
    [jhon@fckrsns ~]$ lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
    sda 8:0 0 698.7G 0 disk
    ├─sda1 8:1 0 200M 0 part /boot
    ├─sda2 8:2 0 128M 0 part
    ├─sda3 8:3 0 279.5G 0 part
    ├─sda4 8:4 0 50G 0 part /
    ├─sda5 8:5 0 25G 0 part
    ├─sda6 8:6 0 100G 0 part /home
    └─sda7 8:7 0 243.9G 0 part
    sr0 11:0 1 1024M 0 rom
    [jhon@fckrsns ~]$ lsblk -f
    NAME FSTYPE LABEL UUID MOUNTPOINT
    sda
    ├─sda1 vfat 4DEB-D6D2 /boot
    ├─sda2
    ├─sda3 ntfs OS 62364BE9364BBCB3
    ├─sda4 ext4 c4da4683-871a-49fa-96a3-4da11387d31d /
    ├─sda5 ntfs Recovery 8ECE4F50CE4F2FAF
    ├─sda6 ext4 3eba01c6-e422-4542-8442-16064c74a563 /home
    └─sda7 ntfs 3B29E7794F6CD932
    sr0
    OS partition (/dev/sda3):
    [jhon@fckrsns /]$ ls /run/media/jhon/OS
    altera Boot djvureader DrWeb Quarantine eSupport hiberfil.sys MSOCache N56VM.BIN pagefile.sys Program Files Recovery SecurityScanner.dll VisualCLibs
    AsusVibeData bootmgr Documents and Settings eclipse Games Intel MS.Office.2007.Portable.micro.v.1.16 N56VZ.BIN PerfLogs Program Files (x86) $Recycle.Bin System Volume Information Windows
    AVScanner.ini BOOTSECT.BAK DOSBox_SIM END gcc Keil_v5 mtd NVIDIA ProgramData Qt R.G. Catalyst Users
    I tried to recover MBR with different ways:
    with syslinux:
    [jhon@fckrsns /]$ sudo dd if=/usr/lib/syslinux/bios/mbr.bin of=/dev/sda
    0+1 records in
    0+1 records out
    440 bytes (440 B) copied, 0.0226394 s, 19.4 kB/s
    with ms-sys:
    [jhon@fckrsns /]$ sudo ms-sys --partition /dev/sda1
    Start sector 2048 (nr of hidden sectors) successfully written to /dev/sda1
    Physical disk drive id 0x80 (C:) successfully written to /dev/sda1
    Number of heads (255) successfully written to /dev/sda1
    [jhon@fckrsns /]$ sudo ms-sys --mbr7 /dev/sda
    Windows 7 master boot record successfully written to /dev/sda
    But there is still no way to boot windows.
    I run grub-mkconfig before and after these manipulations with MBR:
    [jhon@fckrsns ~]$ sudo grub-mkconfig -o /boot/grub/grub.cfg
    Generating grub configuration file ...
    Found linux image: /boot/vmlinuz-linux
    Found initrd image: /boot/initramfs-linux.img
    Found fallback initramfs image: /boot/initramfs-linux-fallback.img
    No volume groups found
    done
    [jhon@fckrsns /]$ sudo os-prober
    /dev/cdrom: open failed: No medium found
    No volume groups found
    I installed rEFInd, now I have two choices on boot screen: vmlinuz-linux, which it founded, and my earlier installed grub bootloader.
    Maybe I missed something, but i don't know what exactly.
    Last edited by Jhon (2014-09-28 16:45:38)

    Now I know that I don't need MBR at all (but google told me that recovering windows = recovering MBR..)
    Are there any ways to recover boot information on EFI system partition from Linux without using Windows Live CD and it's bootrec.exe?
    I have bootmgr and bootmgfw.efi files on /dev/sda3 (partition with windows installed), what else I need? Simple copy of bootmgfw.efi to /boot/EFI/Microsoft/Boot/bootmgfw.efi and addition of custom menu item to /etc/grub.d/40_custom does'nt work. There is Windows now in rEFInd and GRUB menus, but there is error on loading.

  • Arch Linux Pacman Proxy Script

    Since my Arch box has no internet connection (yes, I'm that much of a masochist), I wrote a bash script to act as a proxy of sorts for pacman, at least as regards downloading. It took a while to get it working (intermittent web access and all) but here it finally is, as promised.
    It works well for me, and I only hope that it will help anyone else in the same situation (if there is anyone else in the same situation).
    The script has various options to explain everything you need to know, but here's a quick word of warning: it only works on POSIX-compatible computers (i.e. no Wintendows, usually) and the proxy box needs to have bash, wget, tar, grep and sed installed. I don't see this as being a problem, but if I'm wrong, tell me all about it.
    #!/bin/bash
    readonly VER="2.1"
    readonly wgetVER=`wget -V|sed '1!d'`
    # DEBUG levels:
    # Set to 0 for ALERT-level messages only
    # Set to 1 for INFO-level messages (I prefer this)
    # Set to 2 for DEBUG-level messages
    # Set to 3 for all messages
    readonly DEBUG=0
    # Set DEBUGLOG=1 to print ALERT, INFO and DEBUG messages to DEBUG.log
    readonly DEBUGLOG=0
    readonly COLOUR=true
    if [[ $COLOUR == true ]] ; then
    readonly red='\e[31m'
    readonly warn='\e[31;7m '
    readonly green='\e[32m'
    readonly lgreen='\e[32;1m'
    readonly yellow='\e[33;1m'
    readonly lblue='\e[34;1m'
    readonly dull='\e[0m' ; fi
    # Sticky details:
    # tar seems very slow (vfat? transform? USB?)
    function bugspray {
    [[ -z $2 ]] && verbosity=1 || verbosity=$2
    if (( DEBUG >= verbosity )) ; then
    (( $2 == 0 )) && intro="${warn}ALERT${dull} | "
    (( $2 == 1 )) && intro=" INFO | "
    (( $2 > 1 )) && intro=" ${yellow}DEBUG${dull} | "
    echo -e "$intro$1"
    (( DEBUGLOG == 1 )) && echo "`date +%F_%T` | $1">>log-alpps/DEBUG.log ; fi ; }
    function compare_versions {
    # Requires two ordinary, untweaked version strings, first local, second distant
    if [[ -z $2 ]] ; then
    bugspray "compare_versions didn't receive two variables." 2 ; fi
    update='no'
    [[ -z $2 ]] && return
    local localversion=(`echo $1|sed -r 's/([[:alpha:]]+)/ \1 /g;s/[\.:~_-]/ /g'`)
    local distantversion=(`echo $2|sed -r 's/([[:alpha:]]+)/ \1 /g;s/[\.:~_-]/ /g'`)
    local max=$((${#distantversion[*]}))
    bugspray "localversion: ${localversion[*]}; distantversion: ${distantversion[*]}" 2
    for (( x=0 ; (( x < $max )) ; $((x++)) )) ; do
    bugspray "local version part: `echo ${localversion[$x]}` | distant version part: `echo ${distantversion[$x]}`" 2
    if [[ `echo ${localversion[$x]}|grep -E '^[0-9]*$'` && `echo ${distantversion[$x]}|grep -E '^[0-9]*$'` ]] ; then
    bugspray "Numerical comparison" 2
    bugspray "localver (${localversion[$x]}) less than distantver (${distantversion[$x]}): $(( 10#${localversion[$x]} < 10#${distantversion[$x]} ))" 3
    # Different compare methods for numbers, single letters and multiple letters.
    if (( 10#${localversion[$x]} < 10#${distantversion[$x]} )) ; then
    update='yes'
    break ; fi ; fi
    if [[ `echo ${localversion[$x]}|grep -E '^[[:alpha:]]$'` && `echo ${distantversion[$x]}|grep -E '^[[:alpha:]]$'` ]] ; then # single letter -> compare
    bugspray "Lexicographical comparison" 2
    bugspray "localver (${localversion[$x]}) less than distantver (${distantversion[$x]}): [[ ${localversion[$x]} < ${distantversion[$x]} ]]" 3
    if [[ ${localversion[$x]} < ${distantversion[$x]} ]] ; then
    update='yes'
    break ; fi ; fi
    if [[ `echo ${localversion[$x]}|grep -E '^[[:alpha:]]+$'` && `echo ${distantversion[$x]}|grep -E '^[[:alpha:]]+$'` ]] ; then # string -> drop
    # cvs / git / beta -> what are the rules?
    bugspray "Sequence of letters. Not treating as version number." 2 ; fi
    done ; }
    function find_dependencies {
    # Determine existence via unique path
    bugspray "+ ${lgreen}Building download list for package \"$1\"${dull}" 1
    local packagename
    local dlfile
    local package_found=no
    if [[ `ls .temp-alpps/*.db/$1-* 2>/dev/null` ]] ; then
    bugspray "Analogous package-name file(s) found" 2
    for x in `ls .temp-alpps/*.db/$1-*/desc` ; do
    bugspray "Checking $x" 2
    packagename=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $x`
    if [[ j$packagename == j$1 ]] ; then
    bugspray "Exact match found: $packagename = $1" 2
    dlfile=`sed '/%FILENAME%/,+1!d;/%FILENAME%/d' $x`
    local distantversion=`sed '/%VERSION%/,+1!d;/%VERSION%/d' $x`
    local package_full=$packagename-$distantversion
    local the_repo=`echo $x|sed -r 's/.temp-alpps\/(.*)\.db.*/\1/'`
    local the_path=`echo $x|sed -r 's/desc//'`
    unplus=`echo $packagename|sed 's/\+/\\\+/g'`
    local local_version=`sed -r '/^'$unplus' /!d;s/.* //' .temp-alpps/snapshot.state`
    package_found=yes
    break ; fi ; done ; fi
    if [[ -z $dlfile ]] ; then
    bugspray "Exact match not found -> looking for replacements." 2
    if ! [[ -z `grep $1 .temp-alpps/*.db/*/depends` ]] ; then
    local provisional=`grep $1 .temp-alpps/*.db/*/depends|sed -r 's/\/depends.*//'`
    for package in $provisional ; do
    local providence=`sed -r '/%PROVIDES%/,/^$/!d;/%PROVIDES%/d;/^$/d;s/>.*//;s/=.*//' $package/depends`
    for y in $providence ; do
    if [[ j$y == j$1 ]] ; then
    # But what about when several packages provide the same thing and ALPPS picks the wrong one? Can it happen?
    local newdep=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $package/desc`
    bugspray " -> Package \"$newdep\" provides \"$1\"." 1
    find_dependencies $newdep
    break 2 ; fi ; done ; done
    if [[ -z $newdep ]] ; then
    bugspray "${warn}Warning:${dull} package \"$1\" not found in database." 0 ; fi ; fi ; fi
    bugspray "package: $1 | package_found = $package_found" 2
    # Add file to download_list if not up to date and if not already present
    if [[ j$package_found == jyes ]] ; then
    local already_got_one=no
    unplus=`echo $dlfile|sed 's/\+/\\\+/g'`
    [[ `echo $download_files|grep $unplus` ]] && already_got_one="yes" && bugspray "${green}Package in queue${dull}" 1
    [[ `ls downloads/$dlfile 2>/dev/null` ]] && already_got_one="yes" && bugspray "${green}Package proxied${dull}" 1
    compare_versions $local_version $distantversion
    bugspray "compare_versions says: $update" 2
    ! [[ -z $local_version || $update == yes ]] && already_got_one="yes" && bugspray "${green}Package already installed and up-to-date${dull}" 1
    if [[ j$already_got_one != jyes ]] ; then
    bugspray "${green}Confirm downloading${dull}" 1
    download_files+="$dlfile "
    download_array[${dlfile}]=$the_repo
    bugspray "Checking for further dependencies" 2
    if [[ -a $the_path/depends && `grep -E '^%DEPENDS%$' $the_path/depends` ]] ; then
    local dependency=`sed -r '/%DEPENDS%/d;/^$/q' $the_path/depends`
    bugspray "Dependencies of \"$packagename\":$dependency" 3
    for x in $dependency ; do
    # Is this dependency already installed? Sort-of the same as higher up; it just saves time here.
    local depname=`echo $x|sed -r 's/>.*//;s/=.*//'`
    local depminver=`echo $x|sed -r 's/.*>//'`
    bugspray "Dependency name: \"$depname\"" 2
    if ! [[ `grep -E '^$depname ' .temp-alpps/snapshot.state` ]] ; then
    find_dependencies $depname ; fi ; done
    else
    bugspray "${lblue}End of the line${dull}: package \"$packagename\" has no dependencies." 2
    true ; fi ; fi ; fi ; }
    function failover_fetch {
    echo "Downloading `echo $1|sed 's/.*\///'`"
    [[ -d log-alpps/ ]] || mkdir log-alpps/
    [[ -z $success ]] || unset success
    for mirror in $(<.temp-alpps/snapshot.mirrorlist) ; do
    # If DEBUG>0, shouldn't redirect output
    url=`echo $mirror|sed 's/$arch/'$arch'/;s/$repo/'${download_array[$1]}'/'`/$1
    bugspray "Connecting to $url" 2
    wget -o .temp-alpps/very-temp-log -U "Arch Linux Pacman Proxy Script version $VER / $wgetVER" -P downloads/ $url && success=true
    cat .temp-alpps/very-temp-log>>log-alpps/download.log
    rm -f .temp-alpps/very-temp-log
    if [[ -n $success ]] ; then
    bugspray "Download: \$success = true" 2
    break ; fi ; done
    if [[ -z $success ]] ; then
    bugspray "${warn}FAIL:${dull} $1 not accessible on known mirrors." 0 ; fi ; }
    case $1 in
    warranty)
    echo
    echo -e " ${green}Warranty${dull}"
    echo -e " ${green}========${dull}"
    echo " This program is free software. It comes without any warranty, to"
    echo " the extent permitted by applicable law. You can redistribute it"
    echo " and/or modify it under the terms of the Do What The Fuck You Want"
    echo " To Public License, Version 2, as published by Sam Hocevar. See"
    echo " http://sam.zoy.org/wtfpl/COPYING for more details."
    echo
    howto)
    echo
    echo -e " ${green}How to use ALPPS${dull}"
    echo -e " ${green}================${dull}"
    echo -e " ${yellow}+ Step 0${dull}: prime the engine"
    echo " On your offline box, copy the ALPPS script onto a removable medium, cd into"
    echo " it's directory, then run it with the \"init\" option. This essentially"
    echo " takes a snapshot of your system, package-wise. Your removable medium is"
    echo " now ready for use!"
    echo -e " ${yellow}+ Step 1${dull}:"
    echo " On the proxy box the first order of business is to download and decompress"
    echo " the current package lists. You can do this with the \"fetchdb\" option."
    echo -e " ${yellow}+ Step 1 alt${dull}:"
    echo " If you want to download the package lists without decompressing them,"
    echo " \"fetchdb simple\" will do this. It's a lot quicker, but please keep"
    echo " in mind that you cannot then do anything in step 2."
    echo -e " ${yellow}+ Step 2${dull}:"
    echo " If you want to download packages (and why wouldn't you?), the easiest way"
    echo " is to prepare a simple text file containing the names of the packages you"
    echo " want, one on each line. Run ALPPS with the option \"fetch <filename>\" and"
    echo " sit back and wait until it's done. Don't worry about dependencies: ALPPS"
    echo " handles them automatically."
    echo -e " ${yellow}+ Step 2 alt${dull}:"
    echo " As a convenience, \"fetch full\" will download all the packages needed to"
    echo " update the offline box."
    echo -e " ${yellow}+ Step 3${dull}:"
    echo " Finally, back on your offline box, run ALPPS again with the \"install\""
    echo " option. This will update the package list and copy the package files into"
    echo " local cache. You can now run \"pacman -S <package names>\" to finish"
    echo " installing the packages."
    # ALPPS no longer installs the packages, just caches them locally.
    # Not entirely sure why; it just felt too klutzy.
    echo -e " ${yellow}+ Step 4${dull}:"
    echo " You will now probably want to delete all the stuff you no longer need. Run"
    echo " ALPPS with the option \"clean\". This won't touch your request file(s). It"
    echo -e " ${red}WILL${dull} delete log files, so if you want to keep them, back them up first."
    echo " Next time you do this, don't forget to run ALPPS with \"init\" again."
    echo
    bugs)
    echo
    echo -e " ${green}Where this goes wrong${dull}"
    echo -e " ${green}=====================${dull}"
    echo " + ALPPS is a bit slow when packages have many dependencies. It's a recursive"
    echo " shell script: what did you expect?"
    echo " + It only uses the settings in /etc/pacman.conf. If your conf file is"
    echo " elsewhere, you're SOL. Similarly, the repositories are all taken from"
    echo " /etc/pacman.d/mirrorlist. If you added any custom repositories in"
    echo " /etc/pacman.conf (or any other file), ALPPS ignores them."
    echo " + As it stands, ALPPS only works when the proxy box has bash, wget, sed,"
    echo " grep and tar installed. The offline box needs bash, pacman and sed (in"
    echo " theory, this shouldn't be a problem...)."
    echo " + There is as yet no way of handling package groups, short of listing every"
    echo " member of the group."
    echo " + I don't think ALPPS will ever be able to handle AUR packages. Of course, if"
    echo " you're compiling AUR packages, you probably won't need something like this!"
    echo
    faq)
    echo
    echo -e " ${green}Frequently Asked Questions${dull}"
    echo -e " ${green}==========================${dull}"
    echo
    echo -e " ${red}Q:${dull} Can I run the whole thing off a USB stick?"
    echo -e " ${lblue}A:${dull} Certainly."
    echo
    echo -e " ${red}Q:${dull} Can I use a non-POSIX computer as a proxy (e.g. Windows)?"
    echo -e " ${lblue}A:${dull} Probably not, unless that computer has a POSIX-compatibility layer"
    echo " installed (such as Cygwin) with bash, wget, tar, sed and grep."
    echo
    echo -e " ${red}Q:${dull} Do I need to download the package list, waste time updating my computer,"
    echo " then go back again to download the packages I want?"
    echo -e " ${lblue}A:${dull} Nope! You can update the packagelist database and download piping-hot"
    echo " fresh packages, all in one sitting."
    echo -e " ${red}Q:${dull} You mean I won't have to futz around with package lists that keep updating"
    echo " ten minutes after I download them?"
    echo -e " ${lblue}A:${dull} Exactly. Nice, isn't it?"
    echo
    echo -e " ${red}Q:${dull} Does this thing handle SSL and signed packages?"
    echo -e " ${lblue}A:${dull} ALPPS uses SSL if:"
    echo " - the mirror has an https address (at present, none do), and"
    echo " - wget on the proxy box is compiled with SSL support"
    echo " Concerning signed packages: no, but then again, it doesn't need to. ALPPS"
    echo " downloads packages; it's pacman's responsibility to verify them. Your"
    echo " system remains safe (or as safe as it ever was, at any rate)."
    echo -e " ${red}Q:${dull} What about gpg keys? I need to get them."
    echo -e " ${lblue}A:${dull} ...maybe later, say, in version 3."
    echo
    echo -e " ${red}Q:${dull} ALPPS says it \`prepares databases´. Can pacman still use them after this?"
    echo -e " ${lblue}A:${dull} Yes, it can. In fact, what ALPPS does is extract the databases into a"
    echo " temp directory, without altering the original .db files."
    echo
    echo -e " ${red}Q:${dull} Where can I contact you?"
    echo -e " ${lblue}A:${dull} For constructive, useful questions and comments: [email protected] and"
    echo " be sure to mention Arch Linux in the subject."
    echo " For flames, trolling, spam and the like, visit your local bitbucket."
    echo
    todo)
    echo
    echo -e " ${green}What's next?${dull}"
    echo -e " ${green}============${dull}"
    echo -e " + I ${red}might${dull} be able to extend the reach of this thing to the AUR."
    echo " Yes, I know I said ALPPS couldn't (in \"bugs\"), but I've learned"
    echo " something new since then. It'll be tricky, though, since the AUR web"
    echo " interface delivers results in python. While this should be a Good Thing,"
    echo " bash isn't very good at handling python-format lists and dicts."
    echo
    -v|ver|version|--ver|--version)
    echo -e "${lgreen}Arch Linux pacman proxy script${dull} | ${yellow}version $VER${dull}"
    dl_list) # Debugging
    (( DEBUG == 0 )) && echo "the \"dl_list\" option is only for debugging" && exit 0
    arch=$(<.temp-alpps/snapshot.architecture)
    unset download_files
    unset download_array
    declare -A download_array
    find_dependencies $2
    bugspray "Download list: $download_files" 3
    echo "Download list v2:"
    for x in $download_files ; do
    bugspray " File \"$x\" from repo \"${download_array[$x]}\"" 3
    echo " Full URL: http://mirror.archlinux.org/${download_array[$x]}/os/$arch/$x" ; done
    verint) # Debugging
    (( DEBUG == 0 )) && echo "the \"verint\" option is only for debugging" && exit 0
    for x in `ls .temp-alpps/*/$2-*/desc` ; do
    packagename=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $x`
    if [[ j$packagename == j$2 ]] ; then
    bugspray "Unique package-name file found: $packagename=$2" 2
    distantversion=`sed '/%VERSION%/,+1!d;/%VERSION%/d' $x`
    dlfile=`sed '/%FILENAME%/,+1!d;/%FILENAME%/d' $x`
    package_full=$packagename-$distantversion
    the_repo=`echo $x|sed -r 's/.temp-alpps\/(.*)\.db.*/\1/'`
    the_path=`echo $x|sed -r 's/desc//'`
    local_version=`sed -r '/^'$packagename' /!d;s/.* //' .temp-alpps/snapshot.state`
    break ; fi ; done
    echo "full package filename: $dlfile"
    echo "Comparing local ($local_version) and distant ($distantversion) versions of $2..."
    compare_versions $local_version $distantversion
    #compare_versions 2.5beta3-2 2.5cvs4-1
    echo "...and the verdict is: $update"
    init)
    x=`uname -m`
    if [[ -x /usr/bin/pacman ]] ; then
    [[ -d .temp-alpps ]] || mkdir .temp-alpps/
    pacman -Q>.temp-alpps/snapshot.state
    sed -r '/^Se/!d;s/Server = //' /etc/pacman.d/mirrorlist>.temp-alpps/snapshot.mirrorlist
    sed -r '/^\[/!d;/options/d;s/\[(.*)\]/\1/' /etc/pacman.conf>.temp-alpps/snapshot.repositories
    sed -r '/^Architecture/!d;s/^.*= //' /etc/pacman.conf>.temp-alpps/snapshot.architecture
    [[ ! -s .temp-alpps/snapshot.architecture || auto == $(<.temp-alpps/snapshot.architecture) ]] && $x>.temp-alpps/snapshot.architecture
    sed -r '/^SyncFirst/!d;s/.*= //;s/ /\n/g' /etc/pacman.conf>.temp-alpps/snapshot.prioritypackages
    echo "Current state recorded."
    else
    echo "You seem to be running ALPPs on an unsupported system."
    echo "ALPPS is the ${lgreen}Arch Linux Pacman Proxy Script${dull} and simply"
    echo "won't run properly on a non-pacman OS (except when proxying)."
    echo "Aborting. Sorry."
    exit 1 ; fi
    fetchdb)
    [[ -d downloads ]] || mkdir downloads
    arch=$(<.temp-alpps/snapshot.architecture)
    declare -A download_array
    for repo in $(<.temp-alpps/snapshot.repositories) ; do
    download_array[${repo}.db]=$repo
    location="${repo}.db"
    failover_fetch $location ; done
    if [[ j$2 != jsimple ]] ; then
    [[ -d log-alpps ]] || mkdir log-alpps
    [[ -a syncfirst ]] && rm -f syncfirst
    echo "Preparing databases for local processing. This might take a while."
    for x in $(<.temp-alpps/snapshot.repositories) ; do
    echo "Preparing $x.db"
    if [[ -a downloads/$x.db ]] ; then
    [[ -d .temp-alpps/$x.db ]] || mkdir .temp-alpps/$x.db/
    tar -xzC .temp-alpps/$x.db/ -f downloads/$x.db --transform 's/:/§/' --no-same-owner && echo "$x database ready for use."
    else
    echo -e "Database $x.db is missing. Skipping. This will probably cause problems." ; fi ; done
    # SyncFirst package warning
    [[ -z $download_list ]] || unset download_list
    [[ -a syncfirst ]] && rm -f syncfirst
    for x in $(<.temp-alpps/snapshot.prioritypackages) ; do
    find_dependencies $x ; done
    bugspray "download_files: $download_files" 2
    if [[ ! -z $download_files ]] ; then
    echo "New version(s) of SyncFirst package(s):"
    for x in $(<.temp-alpps/snapshot.prioritypackages) ; do
    [[ ! -z `echo $download_files|grep $x` ]] && echo "- $x" && echo $x>>syncfirst ; done
    echo "Package names placed in 'syncfirst'. Don't forget to download them!" ; fi ; fi
    fetch)
    for x in $(<.temp-alpps/snapshot.repositories) ; do
    if ! [[ -d .temp-alpps/$x.db/ ]] ; then
    bugspray "You must first download a fresh database with the \"fetchdb\" option" 0
    exit 1 ; fi ; done
    arch=$(<.temp-alpps/snapshot.architecture)
    unset download_array
    declare -A download_array
    unset download_files
    if [[ $2 == full ]] ; then
    echo " Building full upgrade list. This will almost certainly take a while."
    echo " Please wait..."
    for y in `sed -r 's/^(.*) .*/\1/' .temp-alpps/snapshot.state` ; do
    bugspray "Examining $y" 1
    find_dependencies $y ; done
    elif [[ -a $2 ]] ; then
    echo " Determining dependencies. This might take a while. Please wait."
    for y in $(<$2) ; do
    bugspray "Examining $y" 1
    find_dependencies $y ; done
    else
    echo " Error: you should provide a list-file or the keyword \"full\"."
    echo " (see 'alpps.sh howto', step 2)"
    exit 1 ; fi
    if [[ -z $download_files ]] ; then
    echo " No files to download: either none found, or all found are up to date."
    else
    [[ -d downloads ]] || mkdir downloads
    for x in $download_files ; do
    failover_fetch $x ; done ; fi
    install)
    dbpath=`sed -r '/^DBPath/!d;s/^.*= //' /etc/pacman.conf`
    [[ -z $dbpath ]] && dbpath="/var/lib/pacman/"
    bugspray "dbpath: $dbpath" 2
    echo " Updating databases"
    cp -ft ${dbpath}sync/ downloads/*.db
    cachedir=`sed -r '/^CacheDir/!d;s/^.*= //' /etc/pacman.conf`
    [[ -z $cachedir ]] && cachedir="/var/cache/pacman/pkg/"
    echo " Caching packages"
    cp -f downloads/*.pkg.tar.xz $cachedir
    echo
    echo " Don't forget to install/update your packages."
    echo " Exercise proper caution."
    echo " Have fun!"
    clean)
    echo "Cleaning up. This might take a while."
    rm -fr .temp-alpps/ && echo "Buffer directory deleted" || echo "Problem deleting buffer directory '.temp-alpps/'"
    rm -fr log-alpps/ && echo "Log directory deleted" || echo "Problem deleting 'log-alpps/'"
    rm -fr downloads/ && echo "Downloaded packages deleted" || echo "Problem deleting 'downloads/'"
    echo
    echo -e " ${lgreen}Arch Linux pacman proxy script${dull}"
    echo
    echo -e " ${green}Description${dull}"
    echo -e " ${green}===========${dull}"
    echo -e " This is a bash script to fetch and install packages for an offline Arch box"
    echo " using another, online box as a proxy of sorts. So far, this only works if"
    echo " the proxy box has bash, wget, tar, sed and grep installed."
    echo " It's probably also entirely unsafe, incompatible and will destroy your box"
    echo " in a fiery blaze if you try to use it (you know the drill)."
    echo
    echo -e " ${green}Options${dull}"
    echo -e " ${green}=======${dull}"
    echo " init Step 0 (as it were): take a snapshot of your system"
    echo " fetchdb Step 1: download the packagelist database"
    echo " fetch <file> Step 2: download requested packages"
    echo " install Step 3: update your system"
    echo " clean Step 4: delete any unneeded files"
    echo
    echo " howto More detailed instructions"
    echo " bugs Problems and future plans"
    echo " faq As it says"
    echo " warranty (in case it ever becomes necessary)"
    echo " version (to be honest, I wasn't expecting to go beyond v1-rc or so)"
    echo " help You're reading it, doofus :^)"
    echo
    # dl_list Test the find_dependencies function"
    # verint Test the compare_versions function"
    esac

    AnimaInvicta wrote:
    Since my Arch box has no internet connection (yes, I'm that much of a masochist), I wrote a bash script to act as a proxy of sorts for pacman, at least as regards downloading. It took a while to get it working (intermittent web access and all) but here it finally is, as promised.
    It works well for me, and I only hope that it will help anyone else in the same situation (if there is anyone else in the same situation).
    The script has various options to explain everything you need to know, but here's a quick word of warning: it only works on POSIX-compatible computers (i.e. no Wintendows, usually) and the proxy box needs to have bash, wget, tar, grep and sed installed. I don't see this as being a problem, but if I'm wrong, tell me all about it.
    #!/bin/bash
    readonly VER="2.1"
    readonly wgetVER=`wget -V|sed '1!d'`
    # DEBUG levels:
    # Set to 0 for ALERT-level messages only
    # Set to 1 for INFO-level messages (I prefer this)
    # Set to 2 for DEBUG-level messages
    # Set to 3 for all messages
    readonly DEBUG=0
    # Set DEBUGLOG=1 to print ALERT, INFO and DEBUG messages to DEBUG.log
    readonly DEBUGLOG=0
    readonly COLOUR=true
    if [[ $COLOUR == true ]] ; then
    readonly red='\e[31m'
    readonly warn='\e[31;7m '
    readonly green='\e[32m'
    readonly lgreen='\e[32;1m'
    readonly yellow='\e[33;1m'
    readonly lblue='\e[34;1m'
    readonly dull='\e[0m' ; fi
    # Sticky details:
    # tar seems very slow (vfat? transform? USB?)
    function bugspray {
    [[ -z $2 ]] && verbosity=1 || verbosity=$2
    if (( DEBUG >= verbosity )) ; then
    (( $2 == 0 )) && intro="${warn}ALERT${dull} | "
    (( $2 == 1 )) && intro=" INFO | "
    (( $2 > 1 )) && intro=" ${yellow}DEBUG${dull} | "
    echo -e "$intro$1"
    (( DEBUGLOG == 1 )) && echo "`date +%F_%T` | $1">>log-alpps/DEBUG.log ; fi ; }
    function compare_versions {
    # Requires two ordinary, untweaked version strings, first local, second distant
    if [[ -z $2 ]] ; then
    bugspray "compare_versions didn't receive two variables." 2 ; fi
    update='no'
    [[ -z $2 ]] && return
    local localversion=(`echo $1|sed -r 's/([[:alpha:]]+)/ \1 /g;s/[\.:~_-]/ /g'`)
    local distantversion=(`echo $2|sed -r 's/([[:alpha:]]+)/ \1 /g;s/[\.:~_-]/ /g'`)
    local max=$((${#distantversion[*]}))
    bugspray "localversion: ${localversion[*]}; distantversion: ${distantversion[*]}" 2
    for (( x=0 ; (( x < $max )) ; $((x++)) )) ; do
    bugspray "local version part: `echo ${localversion[$x]}` | distant version part: `echo ${distantversion[$x]}`" 2
    if [[ `echo ${localversion[$x]}|grep -E '^[0-9]*$'` && `echo ${distantversion[$x]}|grep -E '^[0-9]*$'` ]] ; then
    bugspray "Numerical comparison" 2
    bugspray "localver (${localversion[$x]}) less than distantver (${distantversion[$x]}): $(( 10#${localversion[$x]} < 10#${distantversion[$x]} ))" 3
    # Different compare methods for numbers, single letters and multiple letters.
    if (( 10#${localversion[$x]} < 10#${distantversion[$x]} )) ; then
    update='yes'
    break ; fi ; fi
    if [[ `echo ${localversion[$x]}|grep -E '^[[:alpha:]]$'` && `echo ${distantversion[$x]}|grep -E '^[[:alpha:]]$'` ]] ; then # single letter -> compare
    bugspray "Lexicographical comparison" 2
    bugspray "localver (${localversion[$x]}) less than distantver (${distantversion[$x]}): [[ ${localversion[$x]} < ${distantversion[$x]} ]]" 3
    if [[ ${localversion[$x]} < ${distantversion[$x]} ]] ; then
    update='yes'
    break ; fi ; fi
    if [[ `echo ${localversion[$x]}|grep -E '^[[:alpha:]]+$'` && `echo ${distantversion[$x]}|grep -E '^[[:alpha:]]+$'` ]] ; then # string -> drop
    # cvs / git / beta -> what are the rules?
    bugspray "Sequence of letters. Not treating as version number." 2 ; fi
    done ; }
    function find_dependencies {
    # Determine existence via unique path
    bugspray "+ ${lgreen}Building download list for package \"$1\"${dull}" 1
    local packagename
    local dlfile
    local package_found=no
    if [[ `ls .temp-alpps/*.db/$1-* 2>/dev/null` ]] ; then
    bugspray "Analogous package-name file(s) found" 2
    for x in `ls .temp-alpps/*.db/$1-*/desc` ; do
    bugspray "Checking $x" 2
    packagename=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $x`
    if [[ j$packagename == j$1 ]] ; then
    bugspray "Exact match found: $packagename = $1" 2
    dlfile=`sed '/%FILENAME%/,+1!d;/%FILENAME%/d' $x`
    local distantversion=`sed '/%VERSION%/,+1!d;/%VERSION%/d' $x`
    local package_full=$packagename-$distantversion
    local the_repo=`echo $x|sed -r 's/.temp-alpps\/(.*)\.db.*/\1/'`
    local the_path=`echo $x|sed -r 's/desc//'`
    unplus=`echo $packagename|sed 's/\+/\\\+/g'`
    local local_version=`sed -r '/^'$unplus' /!d;s/.* //' .temp-alpps/snapshot.state`
    package_found=yes
    break ; fi ; done ; fi
    if [[ -z $dlfile ]] ; then
    bugspray "Exact match not found -> looking for replacements." 2
    if ! [[ -z `grep $1 .temp-alpps/*.db/*/depends` ]] ; then
    local provisional=`grep $1 .temp-alpps/*.db/*/depends|sed -r 's/\/depends.*//'`
    for package in $provisional ; do
    local providence=`sed -r '/%PROVIDES%/,/^$/!d;/%PROVIDES%/d;/^$/d;s/>.*//;s/=.*//' $package/depends`
    for y in $providence ; do
    if [[ j$y == j$1 ]] ; then
    # But what about when several packages provide the same thing and ALPPS picks the wrong one? Can it happen?
    local newdep=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $package/desc`
    bugspray " -> Package \"$newdep\" provides \"$1\"." 1
    find_dependencies $newdep
    break 2 ; fi ; done ; done
    if [[ -z $newdep ]] ; then
    bugspray "${warn}Warning:${dull} package \"$1\" not found in database." 0 ; fi ; fi ; fi
    bugspray "package: $1 | package_found = $package_found" 2
    # Add file to download_list if not up to date and if not already present
    if [[ j$package_found == jyes ]] ; then
    local already_got_one=no
    unplus=`echo $dlfile|sed 's/\+/\\\+/g'`
    [[ `echo $download_files|grep $unplus` ]] && already_got_one="yes" && bugspray "${green}Package in queue${dull}" 1
    [[ `ls downloads/$dlfile 2>/dev/null` ]] && already_got_one="yes" && bugspray "${green}Package proxied${dull}" 1
    compare_versions $local_version $distantversion
    bugspray "compare_versions says: $update" 2
    ! [[ -z $local_version || $update == yes ]] && already_got_one="yes" && bugspray "${green}Package already installed and up-to-date${dull}" 1
    if [[ j$already_got_one != jyes ]] ; then
    bugspray "${green}Confirm downloading${dull}" 1
    download_files+="$dlfile "
    download_array[${dlfile}]=$the_repo
    bugspray "Checking for further dependencies" 2
    if [[ -a $the_path/depends && `grep -E '^%DEPENDS%$' $the_path/depends` ]] ; then
    local dependency=`sed -r '/%DEPENDS%/d;/^$/q' $the_path/depends`
    bugspray "Dependencies of \"$packagename\":$dependency" 3
    for x in $dependency ; do
    # Is this dependency already installed? Sort-of the same as higher up; it just saves time here.
    local depname=`echo $x|sed -r 's/>.*//;s/=.*//'`
    local depminver=`echo $x|sed -r 's/.*>//'`
    bugspray "Dependency name: \"$depname\"" 2
    if ! [[ `grep -E '^$depname ' .temp-alpps/snapshot.state` ]] ; then
    find_dependencies $depname ; fi ; done
    else
    bugspray "${lblue}End of the line${dull}: package \"$packagename\" has no dependencies." 2
    true ; fi ; fi ; fi ; }
    function failover_fetch {
    echo "Downloading `echo $1|sed 's/.*\///'`"
    [[ -d log-alpps/ ]] || mkdir log-alpps/
    [[ -z $success ]] || unset success
    for mirror in $(<.temp-alpps/snapshot.mirrorlist) ; do
    # If DEBUG>0, shouldn't redirect output
    url=`echo $mirror|sed 's/$arch/'$arch'/;s/$repo/'${download_array[$1]}'/'`/$1
    bugspray "Connecting to $url" 2
    wget -o .temp-alpps/very-temp-log -U "Arch Linux Pacman Proxy Script version $VER / $wgetVER" -P downloads/ $url && success=true
    cat .temp-alpps/very-temp-log>>log-alpps/download.log
    rm -f .temp-alpps/very-temp-log
    if [[ -n $success ]] ; then
    bugspray "Download: \$success = true" 2
    break ; fi ; done
    if [[ -z $success ]] ; then
    bugspray "${warn}FAIL:${dull} $1 not accessible on known mirrors." 0 ; fi ; }
    case $1 in
    warranty)
    echo
    echo -e " ${green}Warranty${dull}"
    echo -e " ${green}========${dull}"
    echo " This program is free software. It comes without any warranty, to"
    echo " the extent permitted by applicable law. You can redistribute it"
    echo " and/or modify it under the terms of the Do What The Fuck You Want"
    echo " To Public License, Version 2, as published by Sam Hocevar. See"
    echo " http://sam.zoy.org/wtfpl/COPYING for more details."
    echo
    howto)
    echo
    echo -e " ${green}How to use ALPPS${dull}"
    echo -e " ${green}================${dull}"
    echo -e " ${yellow}+ Step 0${dull}: prime the engine"
    echo " On your offline box, copy the ALPPS script onto a removable medium, cd into"
    echo " it's directory, then run it with the \"init\" option. This essentially"
    echo " takes a snapshot of your system, package-wise. Your removable medium is"
    echo " now ready for use!"
    echo -e " ${yellow}+ Step 1${dull}:"
    echo " On the proxy box the first order of business is to download and decompress"
    echo " the current package lists. You can do this with the \"fetchdb\" option."
    echo -e " ${yellow}+ Step 1 alt${dull}:"
    echo " If you want to download the package lists without decompressing them,"
    echo " \"fetchdb simple\" will do this. It's a lot quicker, but please keep"
    echo " in mind that you cannot then do anything in step 2."
    echo -e " ${yellow}+ Step 2${dull}:"
    echo " If you want to download packages (and why wouldn't you?), the easiest way"
    echo " is to prepare a simple text file containing the names of the packages you"
    echo " want, one on each line. Run ALPPS with the option \"fetch <filename>\" and"
    echo " sit back and wait until it's done. Don't worry about dependencies: ALPPS"
    echo " handles them automatically."
    echo -e " ${yellow}+ Step 2 alt${dull}:"
    echo " As a convenience, \"fetch full\" will download all the packages needed to"
    echo " update the offline box."
    echo -e " ${yellow}+ Step 3${dull}:"
    echo " Finally, back on your offline box, run ALPPS again with the \"install\""
    echo " option. This will update the package list and copy the package files into"
    echo " local cache. You can now run \"pacman -S <package names>\" to finish"
    echo " installing the packages."
    # ALPPS no longer installs the packages, just caches them locally.
    # Not entirely sure why; it just felt too klutzy.
    echo -e " ${yellow}+ Step 4${dull}:"
    echo " You will now probably want to delete all the stuff you no longer need. Run"
    echo " ALPPS with the option \"clean\". This won't touch your request file(s). It"
    echo -e " ${red}WILL${dull} delete log files, so if you want to keep them, back them up first."
    echo " Next time you do this, don't forget to run ALPPS with \"init\" again."
    echo
    bugs)
    echo
    echo -e " ${green}Where this goes wrong${dull}"
    echo -e " ${green}=====================${dull}"
    echo " + ALPPS is a bit slow when packages have many dependencies. It's a recursive"
    echo " shell script: what did you expect?"
    echo " + It only uses the settings in /etc/pacman.conf. If your conf file is"
    echo " elsewhere, you're SOL. Similarly, the repositories are all taken from"
    echo " /etc/pacman.d/mirrorlist. If you added any custom repositories in"
    echo " /etc/pacman.conf (or any other file), ALPPS ignores them."
    echo " + As it stands, ALPPS only works when the proxy box has bash, wget, sed,"
    echo " grep and tar installed. The offline box needs bash, pacman and sed (in"
    echo " theory, this shouldn't be a problem...)."
    echo " + There is as yet no way of handling package groups, short of listing every"
    echo " member of the group."
    echo " + I don't think ALPPS will ever be able to handle AUR packages. Of course, if"
    echo " you're compiling AUR packages, you probably won't need something like this!"
    echo
    faq)
    echo
    echo -e " ${green}Frequently Asked Questions${dull}"
    echo -e " ${green}==========================${dull}"
    echo
    echo -e " ${red}Q:${dull} Can I run the whole thing off a USB stick?"
    echo -e " ${lblue}A:${dull} Certainly."
    echo
    echo -e " ${red}Q:${dull} Can I use a non-POSIX computer as a proxy (e.g. Windows)?"
    echo -e " ${lblue}A:${dull} Probably not, unless that computer has a POSIX-compatibility layer"
    echo " installed (such as Cygwin) with bash, wget, tar, sed and grep."
    echo
    echo -e " ${red}Q:${dull} Do I need to download the package list, waste time updating my computer,"
    echo " then go back again to download the packages I want?"
    echo -e " ${lblue}A:${dull} Nope! You can update the packagelist database and download piping-hot"
    echo " fresh packages, all in one sitting."
    echo -e " ${red}Q:${dull} You mean I won't have to futz around with package lists that keep updating"
    echo " ten minutes after I download them?"
    echo -e " ${lblue}A:${dull} Exactly. Nice, isn't it?"
    echo
    echo -e " ${red}Q:${dull} Does this thing handle SSL and signed packages?"
    echo -e " ${lblue}A:${dull} ALPPS uses SSL if:"
    echo " - the mirror has an https address (at present, none do), and"
    echo " - wget on the proxy box is compiled with SSL support"
    echo " Concerning signed packages: no, but then again, it doesn't need to. ALPPS"
    echo " downloads packages; it's pacman's responsibility to verify them. Your"
    echo " system remains safe (or as safe as it ever was, at any rate)."
    echo -e " ${red}Q:${dull} What about gpg keys? I need to get them."
    echo -e " ${lblue}A:${dull} ...maybe later, say, in version 3."
    echo
    echo -e " ${red}Q:${dull} ALPPS says it \`prepares databases´. Can pacman still use them after this?"
    echo -e " ${lblue}A:${dull} Yes, it can. In fact, what ALPPS does is extract the databases into a"
    echo " temp directory, without altering the original .db files."
    echo
    echo -e " ${red}Q:${dull} Where can I contact you?"
    echo -e " ${lblue}A:${dull} For constructive, useful questions and comments: [email protected] and"
    echo " be sure to mention Arch Linux in the subject."
    echo " For flames, trolling, spam and the like, visit your local bitbucket."
    echo
    todo)
    echo
    echo -e " ${green}What's next?${dull}"
    echo -e " ${green}============${dull}"
    echo -e " + I ${red}might${dull} be able to extend the reach of this thing to the AUR."
    echo " Yes, I know I said ALPPS couldn't (in \"bugs\"), but I've learned"
    echo " something new since then. It'll be tricky, though, since the AUR web"
    echo " interface delivers results in python. While this should be a Good Thing,"
    echo " bash isn't very good at handling python-format lists and dicts."
    echo
    -v|ver|version|--ver|--version)
    echo -e "${lgreen}Arch Linux pacman proxy script${dull} | ${yellow}version $VER${dull}"
    dl_list) # Debugging
    (( DEBUG == 0 )) && echo "the \"dl_list\" option is only for debugging" && exit 0
    arch=$(<.temp-alpps/snapshot.architecture)
    unset download_files
    unset download_array
    declare -A download_array
    find_dependencies $2
    bugspray "Download list: $download_files" 3
    echo "Download list v2:"
    for x in $download_files ; do
    bugspray " File \"$x\" from repo \"${download_array[$x]}\"" 3
    echo " Full URL: http://mirror.archlinux.org/${download_array[$x]}/os/$arch/$x" ; done
    verint) # Debugging
    (( DEBUG == 0 )) && echo "the \"verint\" option is only for debugging" && exit 0
    for x in `ls .temp-alpps/*/$2-*/desc` ; do
    packagename=`sed -r '/%NAME%/,+1!d;/%NAME%/d' $x`
    if [[ j$packagename == j$2 ]] ; then
    bugspray "Unique package-name file found: $packagename=$2" 2
    distantversion=`sed '/%VERSION%/,+1!d;/%VERSION%/d' $x`
    dlfile=`sed '/%FILENAME%/,+1!d;/%FILENAME%/d' $x`
    package_full=$packagename-$distantversion
    the_repo=`echo $x|sed -r 's/.temp-alpps\/(.*)\.db.*/\1/'`
    the_path=`echo $x|sed -r 's/desc//'`
    local_version=`sed -r '/^'$packagename' /!d;s/.* //' .temp-alpps/snapshot.state`
    break ; fi ; done
    echo "full package filename: $dlfile"
    echo "Comparing local ($local_version) and distant ($distantversion) versions of $2..."
    compare_versions $local_version $distantversion
    #compare_versions 2.5beta3-2 2.5cvs4-1
    echo "...and the verdict is: $update"
    init)
    x=`uname -m`
    if [[ -x /usr/bin/pacman ]] ; then
    [[ -d .temp-alpps ]] || mkdir .temp-alpps/
    pacman -Q>.temp-alpps/snapshot.state
    sed -r '/^Se/!d;s/Server = //' /etc/pacman.d/mirrorlist>.temp-alpps/snapshot.mirrorlist
    sed -r '/^\[/!d;/options/d;s/\[(.*)\]/\1/' /etc/pacman.conf>.temp-alpps/snapshot.repositories
    sed -r '/^Architecture/!d;s/^.*= //' /etc/pacman.conf>.temp-alpps/snapshot.architecture
    [[ ! -s .temp-alpps/snapshot.architecture || auto == $(<.temp-alpps/snapshot.architecture) ]] && $x>.temp-alpps/snapshot.architecture
    sed -r '/^SyncFirst/!d;s/.*= //;s/ /\n/g' /etc/pacman.conf>.temp-alpps/snapshot.prioritypackages
    echo "Current state recorded."
    else
    echo "You seem to be running ALPPs on an unsupported system."
    echo "ALPPS is the ${lgreen}Arch Linux Pacman Proxy Script${dull} and simply"
    echo "won't run properly on a non-pacman OS (except when proxying)."
    echo "Aborting. Sorry."
    exit 1 ; fi
    fetchdb)
    [[ -d downloads ]] || mkdir downloads
    arch=$(<.temp-alpps/snapshot.architecture)
    declare -A download_array
    for repo in $(<.temp-alpps/snapshot.repositories) ; do
    download_array[${repo}.db]=$repo
    location="${repo}.db"
    failover_fetch $location ; done
    if [[ j$2 != jsimple ]] ; then
    [[ -d log-alpps ]] || mkdir log-alpps
    [[ -a syncfirst ]] && rm -f syncfirst
    echo "Preparing databases for local processing. This might take a while."
    for x in $(<.temp-alpps/snapshot.repositories) ; do
    echo "Preparing $x.db"
    if [[ -a downloads/$x.db ]] ; then
    [[ -d .temp-alpps/$x.db ]] || mkdir .temp-alpps/$x.db/
    tar -xzC .temp-alpps/$x.db/ -f downloads/$x.db --transform 's/:/§/' --no-same-owner && echo "$x database ready for use."
    else
    echo -e "Database $x.db is missing. Skipping. This will probably cause problems." ; fi ; done
    # SyncFirst package warning
    [[ -z $download_list ]] || unset download_list
    [[ -a syncfirst ]] && rm -f syncfirst
    for x in $(<.temp-alpps/snapshot.prioritypackages) ; do
    find_dependencies $x ; done
    bugspray "download_files: $download_files" 2
    if [[ ! -z $download_files ]] ; then
    echo "New version(s) of SyncFirst package(s):"
    for x in $(<.temp-alpps/snapshot.prioritypackages) ; do
    [[ ! -z `echo $download_files|grep $x` ]] && echo "- $x" && echo $x>>syncfirst ; done
    echo "Package names placed in 'syncfirst'. Don't forget to download them!" ; fi ; fi
    fetch)
    for x in $(<.temp-alpps/snapshot.repositories) ; do
    if ! [[ -d .temp-alpps/$x.db/ ]] ; then
    bugspray "You must first download a fresh database with the \"fetchdb\" option" 0
    exit 1 ; fi ; done
    arch=$(<.temp-alpps/snapshot.architecture)
    unset download_array
    declare -A download_array
    unset download_files
    if [[ $2 == full ]] ; then
    echo " Building full upgrade list. This will almost certainly take a while."
    echo " Please wait..."
    for y in `sed -r 's/^(.*) .*/\1/' .temp-alpps/snapshot.state` ; do
    bugspray "Examining $y" 1
    find_dependencies $y ; done
    elif [[ -a $2 ]] ; then
    echo " Determining dependencies. This might take a while. Please wait."
    for y in $(<$2) ; do
    bugspray "Examining $y" 1
    find_dependencies $y ; done
    else
    echo " Error: you should provide a list-file or the keyword \"full\"."
    echo " (see 'alpps.sh howto', step 2)"
    exit 1 ; fi
    if [[ -z $download_files ]] ; then
    echo " No files to download: either none found, or all found are up to date."
    else
    [[ -d downloads ]] || mkdir downloads
    for x in $download_files ; do
    failover_fetch $x ; done ; fi
    install)
    dbpath=`sed -r '/^DBPath/!d;s/^.*= //' /etc/pacman.conf`
    [[ -z $dbpath ]] && dbpath="/var/lib/pacman/"
    bugspray "dbpath: $dbpath" 2
    echo " Updating databases"
    cp -ft ${dbpath}sync/ downloads/*.db
    cachedir=`sed -r '/^CacheDir/!d;s/^.*= //' /etc/pacman.conf`
    [[ -z $cachedir ]] && cachedir="/var/cache/pacman/pkg/"
    echo " Caching packages"
    cp -f downloads/*.pkg.tar.xz $cachedir
    echo
    echo " Don't forget to install/update your packages."
    echo " Exercise proper caution."
    echo " Have fun!"
    clean)
    echo "Cleaning up. This might take a while."
    rm -fr .temp-alpps/ && echo "Buffer directory deleted" || echo "Problem deleting buffer directory '.temp-alpps/'"
    rm -fr log-alpps/ && echo "Log directory deleted" || echo "Problem deleting 'log-alpps/'"
    rm -fr downloads/ && echo "Downloaded packages deleted" || echo "Problem deleting 'downloads/'"
    echo
    echo -e " ${lgreen}Arch Linux pacman proxy script${dull}"
    echo
    echo -e " ${green}Description${dull}"
    echo -e " ${green}===========${dull}"
    echo -e " This is a bash script to fetch and install packages for an offline Arch box"
    echo " using another, online box as a proxy of sorts. So far, this only works if"
    echo " the proxy box has bash, wget, tar, sed and grep installed."
    echo " It's probably also entirely unsafe, incompatible and will destroy your box"
    echo " in a fiery blaze if you try to use it (you know the drill)."
    echo
    echo -e " ${green}Options${dull}"
    echo -e " ${green}=======${dull}"
    echo " init Step 0 (as it were): take a snapshot of your system"
    echo " fetchdb Step 1: download the packagelist database"
    echo " fetch <file> Step 2: download requested packages"
    echo " install Step 3: update your system"
    echo " clean Step 4: delete any unneeded files"
    echo
    echo " howto More detailed instructions"
    echo " bugs Problems and future plans"
    echo " faq As it says"
    echo " warranty (in case it ever becomes necessary)"
    echo " version (to be honest, I wasn't expecting to go beyond v1-rc or so)"
    echo " help You're reading it, doofus :^)"
    echo
    # dl_list Test the find_dependencies function"
    # verint Test the compare_versions function"
    esac
    I've always resorted to use VPN, then I started using cntlm, this looks very useful (and a lot of work on your part!) Thanks alot!
    DoctorZeus

  • 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?

  • Dual boot Windows 7 (64) and Arch Linux (64) problems

    Hello:
    I am new to Arch Linux and just finished installing the 64bit on my laptop. It had a prebuilt Windows 7 (64) installed which I kept but split the hdd from 160Gb to 80Gb and 80Gb. I installed Arch there and set 4 partitions, all of them as Logical - a 64 MB ext2 /boot partition; a 512 MB swap partition; a 15 GB root partition; and the rest as my /home partition. My partitions look like this:
    Disk Drive: /dev/sda
    Size: 160041885696 bytes, 160.0 GB
    Heads: 255 Sectors per Track: 63 Cylinders: 19457
    Name Flags Part Type FS Type [Label] Size (MB)
    sda1 Primary Unknown (27) 12889.02
    sda2 Boot Primary NTFS 106.93
    sda3 Primary NTFS [] 73915.11*
    sda5 Logical Linux ext2 65.81*
    sda6 Logical Linux 509.97*
    sda7 Logical Linux ext2 15002.92*
    sda8 Logical Linux ext2 57549.55*
    The install was succesful(this was running from the core install cd) and I installed GRUB to my /boot but when I restarted it loaded Windows 7. I have used Knoppix USB disc to boot and see my Arch Linux install files and edited the /boot/gur/menu.lst file.
    In Windows I installed EasyBCD 1.7.2 and tried to get NeoGrub bootloader working as a dual boot. I tried getting rid of the boot flag for Windows with cfdisk and setting it to my (Logical) sda5. That did not work. So far the only way I have booted into my Arch Linux install has been by going to the Live CD, choosing "Boot from Existing Linux Install" and editing the command files there.
    root (hd0,4)
    kernel /vmlinuz26 root=/dev/sda3 ro
    initrd /kernel26.img
    My goal is to get a dual boot working for Windows 7 and Arch Linux 64 and continue installing the Xorg and KDE to Arch. I just don't know what the problem is here. I don't mind reinstalling Arch if something went wrong, but I would like to keep my Windows running in order and add Arch on.
    Any help would be greatly appreciated.

    I ran the LiveCD and chose "Install to MBR hd0". I ended up with this:
    setup hd(0,1)
    Checking if "/boot/grub/stage1" exists.....yes
    Checking if "/boot/grub/iso9660_stage1_5" exists.....yes
    Running "embed /boot/grub/iso9660_stage1_5 (hd0,1)".....failed(this is not fatal)
    Running "embed /boot/grub/iso9660_stage1_5 (hd16)".....failed(this is not fatal)
    Running "install /boot/grub/stage1 d (hd0,1) /boot/grub/stage2 p (hd0,1) boot/grub/menu.lst".....failed
    Error 31: File is not sector aligned
    My entry for Windows into the menu.lst looks like this:
    # (0) Arch Linux x64
    title Arch Linux x64
    root (hd0,4)
    kernel /vmlinuz26 root=/dev/disk/by-uuid/3841273c-d91e-41d6-9dbf-716a15d03a01 ro
    initrd /kernel26.img
    # (1) Arch Linux x64
    title Arch Linux x64 Fallback
    root (hd0,4)
    kernel /vmlinuz26 root=/dev/disk/by-uuid/3841273c-d91e-41d6-9dbf-716a15d03a01 ro
    initrd /kernel26-fallback.img
    # (2) Windows 7
    title Windows 7
    rootnoverify (hd0,0)
    makeactive
    chainloader +1

  • [GUIDE] How to get MapleStory working in Arch Linux

    MapleStory is a free-of-charge, 2D, side-scrolling massively multiplayer online role-playing game developed by the South Korean company Wizet. Several versions of the game are available for specific countries or regions, and each is published by various companies such as Wizet and Nexon. Although playing the game is free, character appearances and gameplay enhancements can be purchased from the "Cash Shop" using real money. MapleStory has a combined total of over 50 million subscriber accounts in all of its versions. MapleStory North America (Global), for players mainly in North America and outside of East Asia, Southeast Asia and Europe, has over three million players.
    In the game, players travel the "Maple World", defeating monsters and developing their characters' skills and abilities as is typical in role-playing games. Players can interact with others in many ways, such as through chatting, trading, and playing minigames. Groups of players can band together in parties to hunt monsters and share the rewards. Players can also join a guild to interact more easily with each other.
    I am an avid mapler myself, however, I am also an avid archer! For some time, I have wanted to get MapleStory working on Arch Linux in some way, but nothing seemed to work. As you might have guessed by now, recently, while playing around with VirtualBox, I discovered a method to get MapleStory working on it! Though in this method you won't actually have MapleStory running on Arch Linux, you'll have it running on a VirtualBox Windows virtual machine, that is still pretty good compared to other people's experiences.
    I hope there are at least a few maplers on this forum, and if there aren't, I hope that someone will port this post over to other Linux, or even MapleStory, forums. Anyways, let's begin.
    1. Download and install a version of Virtual Box that is version 3.0+. The reason for this is that, only versions 3.0+ support an experimental DirectX Driver with 3D acceleration that is required for MapleStory to run.
    2. Create a Windows Virtual Machine, add a hard disk to it, and install and update Windows on it(preferably Windows XP, as it uses less resources than other contemporary Windows installations).
    3. Once you have done all you needed and wanted on that Windows installation, restart it, boot it into safe mode by holding F8 at the boot, and wait until the desktop is fully loaded.
    4. After you are at the desktop, go to "Devices" at the top of the menu of the Windows virtual machine, and select "Install Guest Additions...". Wait until Guest Additions finishes installing, and when VirtualBox asks you if you want to mount the disk containing the Guest Additions on the virtual machine, say "Yes".
    5. Run the main executable on the disk that doesn't have amd64 or x86 following its name. Follow the instructions it gives you, and when it asks you what components to install, make sure both of the boxes it shows you are checked.
    6. After the install is completed, the virtual machine will restart. After it restarts, shut it down.
    7. Congratulations! You now have DirectX installed on your VirtualBox virtual machine! Now you need to activate the "3D Acceleration", that enables it.
    8. In the VirtualBox main window, make sure you have your machine with Windows selected. Then, click on "Machine", and then "Settings...", at the top. A new window should pop up. On the left hand side, click on the display panel, and in the new settings section, tick Enable 3D Acceleration. Click "OK", to save the settings.
    9. Start your Windows virtual machine, install MapleStory just as you would on a normal windows computer, and run MapleStory.
    Notes: This way of running MapleStory is slower than by running it normally, on a normal windows computer. Also, try to not interact with your Linux desktop while playing MapleStory, because this can cause HackShield to shut down MapleStory, due to the fact that it believes there is a hacking attempt.
    If any of you port this guide to any other place on the web, please, credit me, neovaysburd5.
    For any further questions or inquiries, this goes to all of you, please contact me at [email protected].
    Last edited by neovaysburd5 (2009-08-19 16:51:31)

    Alright, I've posted it in the wiki. I don't know if it meets the Arch Linux wiki standards, so if there is absolutely anything wrong with it, please fix it right away. Don't even ask my permission.
    http://wiki.archlinux.org/index.php/MapleStory

Maybe you are looking for

  • Bootcamp Windows 7 on iMac Startup Freezes

    Ok, so I have tried installing Windows 7 like 10 times & with every install, after doing all Bootcamp Updates & Windows Updates, I get a Frozen Startup at the beginning where it says Windows & the little colored dots start loading. It always freezes

  • How to use the G/L Accounts, COA and related transactions from the SDK?

    Hi all Where can I find more documentation or examples on how to manipulate the G/L Accounts?  Does SAP makes journal entries automatically from an User Defined Table, Form or Field? If I indicate an account to my table, how does the amounts entered

  • Error while integrating E-biz with Oracle B2B

    I am trying to integrate Oracle apps with Oracle B2B. I have updated Transport Server Details : XML Gateway Inbound/XML Gateway Outbound with IP,user name,password and Sid. Then created an agreement with Internal Delivery Channel as XML Gateway Outbo

  • Problem logging into server.

    i have a macbook pro running 10.6 imac running 10.6 macpro running server 10.5.8 MBP logs into iMac no problem, iMac ARD and Sharing settings are identical to server, but server will not allow login without asking permission (so i know server see's i

  • I have two blackberry's that won't load

    I have two blackberry 8520 that won't load the operating system one loads a third then switches off and on,the other loads and writes reload software...I've tried force detection it does not show me any ports I downloaded the software but still nothi