nikolas-n / GNU-Linux-on-Asus-C201-Chromebook

Links and guides about GNU/Linux on Asus C201 (C201P and C201PA) chromebook (veyron_speedy)
47 stars 6 forks source link

Teamwork With The C100P (Asus Flip)? #7

Open freecicero opened 3 years ago

freecicero commented 3 years ago

I just spent some time this weekend getting my C100 running linux and I wonder if an image created for the C100 would run on the C201. I gave up trying to make the Arch linux work but I found that the veyron image produced by Kali works fairly well and seems to be updating after some tweaks. As of this moment they have pulled their current veyron link but I found the 2020.1 edition and it shows a lot of promise. KDE desktop seems to be working well but for some reason my XFCE is freezing. Here are some notes I made along the way:

Source for 2020.1 Kali Image (as of 1/3/21 - as of this date Kali has removed the link from its page, but I saw a note at Kali that they hoped to update the veyron image after they worked out a problem):

https://linuxtracker.org/index.php?page=torrent-details&id=20a3d183df46f06fe989ed234c0e2ddd32d4fd30

https://www.kali.org/docs/arm/kali-linux-asus-chromebook-flip/

Info on getting past error in apt-get-upgrade due to libgcc-9 problem: -- https://crazytechgo.com/libgcc-9-dev-install-kali-linux/


Info on expanding the image to a usable size after installing the image (which is only 7 gb or so) to an SD Card:

https://forums.kali.org/showthread.php?27350-Chromebook-expand-resize-grow-partition-rootfs Increase the size to full capacity (from these notes, just install the cloud-guest-utils package and then run growpart and resize2fs using /dev/sda2 as target :

apt download cloud-guest-utils

growpart /dev/sda 2

resize2fs /dev/sda2

Note that the first has the 2 out with a space; the second command references sda2

if use the microsd card then need to use the instructions mmcblk0

Good news everyone! I've figured out a way to do it reliably. The following steps are expected to be taken from a Chromebook that is booted from an sdcard. Modify the device name if you're using USB.

Code: mkdir growpart cd growpart apt download cloud-guest-utils dpkg-deb -x cloud-guest.utils . #Note: The period at the end is not a typo and is required. It's saying to extract into the current directory. cd usr/bin ./growpart /dev/mmcblk1 2 # You will need to make sure your sdcard is mmcblk1 - it'll typically be the only one in the output of ls /dev/mmcblk* that has 2 partitions. resize2fs /dev/mmcblk1p2 # Again, make sure you're using the correct partition. Also note that while the command may seem to be "frozen" - it's working and may take a while. cgpt repair /dev/mmcblk1


The stock image comes with XFCE. I installed KDE alongside and it seems to work well, but now(?) my XFCE seems to be freezing. KDE had a problem with no network manager showing. I installed plasma-nm and rebooted and the network manager icon appear in the panel. I installed synaptic too and that seems to load, but trying to install something freezes the machine.

Not sure if I should uninstall XFCE or try to get it to stop freezing.


I am toying with the idea of getting a C201 for the bigger screen and I wonder if my image for the C100 would work as is on the C201. Any idea what likelihood of success might be? If anyone has time to test it ought to be as easy as downloading and burning an sd card or usb with the kali image linked above.

These are really nice machines and it would be great to have a community somewhere to support them - maybe here? If the images are interchangeable we might be able to save people a lot of time on some very nice machines.

harvp0wn commented 3 years ago

I went pretty deep into the C100p archlinux rabbit hole. I think I finally have a system that is usable and reliable. I just posted some of my setup files to hopefully help others out. https://github.com/harvp0wn/Asus-C100P-Chromebook

cracket commented 3 years ago

I'm interested in C100P too - but what I would like to achieve is mainline kernel 5.x supporting all builtin hardware (including blobs) Previously used Kali, but looks like it's unsupported now. @harvp0wn @freecicero - you can count me in

freecicero commented 3 years ago

Glad to hear from you cracket, and I had not seen Harvpown's post til today. The C100P continues to be my only ARM machine and i'd really like to get more use out of it. My kali image is still working from SD card, but it sure would be nice to eventually be able to install natively to the machine since the chromeos is no longer being updated.

freecicero commented 3 years ago

Also, in the event we were to try installing a newer kernel, where would we find it? I don't see any veyron listed here: https://http.kali.org/kali/pool/main/l/linux/ Is there another place to look?

harvp0wn commented 3 years ago

Arch has a guide for installing the mainline kernel but it would break the WiFi. I tried using the same fix on my post for the veyron kernel but it did not work. If you guys figure it out please let me know.I love this little computer.

https://archlinuxarm.org/platforms/armv7/rockchip/asus-chromebook-flip-c100p

cracket commented 3 years ago

So regarding kali - they have stopped releasing binaries for c100, I have found the last ones 2019-3, 2019-4 and 2020-1 built images from kali (available via torrents), but since then there are no new builds (at least I haven't found any). It's possible to use old image and update packages, but there is some mess with xfce & main menu, so it's usable, but definitely there are packaging issues there. The kali build scripts look updated on monthly basis, but haven't built kernel from it yet. https://gitlab.com/kalilinux/build-scripts/kali-arm

Wifi works with mainline kernel but it requires to put proper blobs to /lib/firmware. My temporary solution for now is to use build scripts from PrawnOS to build blobby_kernel but still didn't figure out how to setup blobs for bluetooh. PrawnOS builds the whole system image& requires big debian VM to do so (they mentioned docker should work, but it didn't in my case). On the other hand they hate blobs, and claim they don't support it, but pipeline builds blobby kernel But my VM takes 20GB of disk space, I would love to work out some docker based solution just to build the kernel, as injecting kernel into any distro is very simple.

freecicero commented 3 years ago

I know what you mean cracket about the mess with xfce. In my case xfce will usually run for a few minutes but eventually freezes the entire computer. I have had better success with Plasma, however, and although I seem to still get a few occasional freezes, plasma seems to me to be running without issue (all this is in reference to my install from the kali 2020-1 image, updated as best possible using apt.

cracket commented 3 years ago

@harvp0wn the wifi works flawlessly if you have proper bin in /lib/firmware, there might be a challenge to make both wifi&bt working, but I have some idea how to make them work. I will post some howto as soon as I end testing

cracket commented 3 years ago

I've found the way how to make bluetooth working, but it's not compatible with other features, now testing with ubuntu 20 on c100.

harvp0wn commented 3 years ago

@cracket Arch. Thanks for the help but I seem to be struggling with this. I have copied to files from the chromeos directory to arch /lib/firmware but still no luck. wlan0 is not showing up. The files I am copying are:

BCM4354_003.001.012.0443.1505.hcd
brcmfmac4354-sdio.bin BCM4354.hcd
brcmfmac4354-sdio.txt

I must be missing something ???

cracket commented 3 years ago

@harvp0wn my first guess is you forgot to use /lib/firmware/brcm as directory for brcm firmware But feel free to attach your dmesg output, maybe I will be able to figure it out. If you need some inspiration - I'm trying to write up some notes about kernel settings, see here: https://github.com/cracket/c100/blob/main/hardware.md

harvp0wn commented 3 years ago

@harvp0wn my first guess is you forgot to use /lib/firmware/brcm as directory for brcm firmware But feel free to attach your dmesg output, maybe I will be able to figure it out. If you need some inspiration - I'm trying to write up some notes about kernel settings, see here: https://github.com/cracket/c100/blob/main/hardware.md

Thank you so much! I greatly appreciate this. It seems so simple now but I was stuck on this for so long. Thank you for the link aswell.