Showing posts with label virtualbox settings. Show all posts
Showing posts with label virtualbox settings. Show all posts

Wednesday, May 18, 2022

NetBSD stuff

 mk.conf:

MAKE_JOBS=      4
DEPENDS_TARGET= bin-install

 ---

VBoxManage setextradata "NetBSD-92amd" CustomVideoMode1 1920x1080x32

 vesa list

vesa 0x160

---

 

Wednesday, January 5, 2022

NetBSD on VB - no more hacks! (or at least a lot less)


 Normally doing a NetBSD desktop on VirtualBox involves a convoluted ritual on both host and guest. I still need to do VBoxManage for the host setup, but I've discovered something interesting. For the guest, all I need to do is specify a vesa setting, like this: 

menu=Boot normally:rndseed /var/db/entropy-file;vesa 0x160;boot

...and I get a nice, rich but readable console, and a 1920x180 desktop in X too; without configuring X in any way. This works in VBoxSVGA and VMSVGA. 

Best of all, I get a respectable sized console in full-screen mode -without X. Instead of a tiny 640x480 screen I get a console like this:


 
This is a game-changer! No more X (at least, it's optional), no more scaled mode. It's not perfect, but it's a serious improvement!
 
 

Saturday, February 6, 2021

Note to future self, feb 2021

This blog post details a personal workflow experiment. This is for my own use only -if you found this entry because of google, whatever you should be aware that none of this is recommended. It's shit I'm trying for myself.

Tuesday, January 12, 2021

OI on VB; quick note-to-self

 To get proper graphics, the following need to be done: 

C:\Program Files\Oracle\VirtualBox>VBoxManage.exe setextradata OI-2021 CustomVideoMode1 1920x1080x16


C:\Program Files\Oracle\VirtualBox>VBoxManage modifyvm OI-2021 --graphicscontroller vboxvga

The resolution may/may not need to be adjusted in MATE (preferences -> system -> displays).

The text installer (an option from the mate boot disk) allows you to specify an IP and default router, instead of having it handled by Network Manager. 

Monday, October 7, 2019

Debian Testing in a VB VM (2019/2020 edition)

To install guest additions, first:

sudo apt update -y && apt upgrade
sudo apt install dkms linux-headers-$(uname -r) build-essential
 
Then:
cd /media/cdrom0/; /bin/sh VBo*run
 
To set up ISO files as a local repository: 

1)Download the files somewhere. I use /.iso:
 
random@flustered:~$ ls -l /.iso
total 12833380
dr-xr-xr-x 1 root   root         4096 Oct  6 20:57 1
dr-xr-xr-x 1 root   root         2048 Oct  6 21:13 2
dr-xr-xr-x 1 root   root         2048 Oct  6 21:15 3
-rwxr-xr-x 1 random random 3838230528 Oct  7 09:23 debian-testing-amd64-DVD-1.iso
-rwxr-xr-x 1 random random 4619786240 Oct  7 09:25 debian-testing-amd64-DVD-2.iso
-rwxr-xr-x 1 random random 4683341824 Oct  7 09:27 debian-testing-amd64-DVD-3.iso
random@flustered:~$
 
2) create mountpoints (mkdir /.iso{1,2,3}). 
3) add the mountpoints to /etc/fstab:
 
random@flustered:~$ cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
#                
# / was on /dev/sda1 during installation
UUID=4c /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda5 during installation
UUID=28 none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0
/.iso/debian-testing-amd64-DVD-1.iso /.iso/1 iso9660     ro,loop,auto    0       0
/.iso/debian-testing-amd64-DVD-2.iso /.iso/2 iso9660     ro,loop,auto    0       0
/.iso/debian-testing-amd64-DVD-3.iso /.iso/3 iso9660     ro,loop,auto    0       0
random@flustered:~$
 
4) make the proper changes to /etc/apt/sources.list:

deb [trusted=yes] file:/.iso/1 bullseye contrib main
deb [trusted=yes] file:/.iso/2 bullseye contrib main
deb [trusted=yes] file:/.iso/3 bullseye contrib main
 
...it's important to put "[trusted=yes]", or apt won't process them.
5)apt update to use the new sources
...and you're good to go.

Thursday, November 23, 2017

Long time, no nix!

Actually, that's not exactly true. I've been playing with the usual things and not really treading any new ground to speak of.

I've been playing off-and-on with NetBSD 8 in a virtualbox VM since May.

It's gotten a lot better (from my point of view). It's almost nearly useable as a replacement for Mint 18 ...almost. The performance isn't really there.

...and it wouldn't be, since there are no guest additions.

There are two tricks I've learned that makes life in VB a lot better for NetBSD 8:

1)SetExtras;
From the hosts' commandline:

VBoxManage setextradata $VMNAME CustomVideoMode1 1920x1080x16 

The "x16" is important. Your instinct will be to choose a color depth of 24, but it won't work. 16 will.

2)Use a custom xorg.conf in the guest:

I'm still working on this (is there a way to make Xorg see more ram? There's gotta be!), but this is what I have to date:
Section "ServerLayout"
    Identifier     "X.org Configured"
    Screen      0  "Screen0" 0 0
    InputDevice    "Mouse0" "CorePointer"
    InputDevice    "Keyboard0" "CoreKeyboard"
EndSection

Section "Files"
    ModulePath   "/usr/X11R7/lib/modules"
    FontPath     "/usr/X11R7/lib/X11/fonts/misc/"
    FontPath     "/usr/X11R7/lib/X11/fonts/TTF/"
    FontPath     "/usr/X11R7/lib/X11/fonts/Type1/"
    FontPath     "/usr/X11R7/lib/X11/fonts/75dpi/"
    FontPath     "/usr/X11R7/lib/X11/fonts/100dpi/"
EndSection

Section "Module"
    Load  "dri"
    Load  "dri2"
    Load  "glx"
    Load  "shadow"
EndSection

Section "InputDevice"
    Identifier  "Keyboard0"
    Driver      "kbd"
EndSection

Section "InputDevice"
    Identifier  "Mouse0"
    Driver      "mouse"
    Option        "Protocol" "wsmouse"
    Option        "Device" "/dev/wsmouse"
    Option        "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
    Identifier   "Monitor0"
    VendorName   "Monitor Vendor"
    ModelName    "Monitor Model"
    HorizSync    31-80
    VertRefresh  30-100
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: : integer, : float, : "True"/"False",
        ### : "String", : " Hz/kHz/MHz",
        ### : "%"
        ### [arg]: arg optional
        #Option     "ShadowFB"               # []
        #Option     "DefaultRefresh"         # []
        #Option     "ModeSetClearScreen"     # []
    Identifier  "Card0"
    Driver      "vesa"
    BusID       "PCI:0:2:0"
EndSection

Section "Screen"
    DefaultDepth 16
    Identifier "Screen0"
    Device     "Card0"
    Monitor    "Monitor0"
    SubSection "Display"
        Viewport   0 0
        Depth     16
    EndSubSection
#    SubSection "Display"
#        Viewport   0 0
#        Depth     24
#        Modes     "1920x1080"
#    EndSubSection
EndSection
I've also found that setting RAM between 4G and 6G is needed for larger apps (CLang, GCC) to finish compiling.




I've managed to compile xfce4 and MATE; Mate works well enough to use as a desktop.

Most applications I've tried so far work, with some exceptions:
1)Firefox "nightly" randomly crashes.
2)Codeblocks stalls and never completely starts
3)htop doesn't seem to report free RAM correctly
4)closing apps sometimes crashes MATE
5)vlc player doesn't handle videos as well as gnome-mplayer (it's unwatchable).

Again, it's very much a case of "so near and yet so far". All said and done though, after three days of compiling everything (source, pkgsrc) I have a reasonably functional desktop with most of the comforts of home.

NetBSD 8 is still in beta, of course -and it shows. But I'm having better luck with it and pkgsrc (under virtualbox) than I have with NetBSD 7.x, so I'm optimistic this will be a keeper once it's done!

automating zfs mounts -a quick and very dirty script

 #!/bin/sh for x in obj xsrc src pkgsrc pkgsrc/distfiles pkgsrc/packages pkg         do zfs create ext/$x zfs set mountpoint=/usr/$x ext/$x ...