osx dropbox continue upload when monitor sleep

macOS 11 Big Sur has now been released! If you lot'd like that version instead then please apply my new Big Sur installation guide!

This tutorial for installing macOS Catalina using OpenCore has been adapted for Proxmox from Kholia's OSX-KVM project and Leoyzen's OpenCore configuration for KVM. You tin can get the full sourcecode on my GitHub here.

If you'd like to employ Clover instead, use my older tutorial, simply OpenCore works better!

Requirements

I'll presume you already accept Proxmox 6.one or half dozen.2 installed. You likewise demand a real Mac available in order to fetch the OSK key.

Your Proxmox host computer'due south CPU must support SSE 4.2, then for Intel your CPU must be at to the lowest degree as new as Nehalem, which was the outset CPU generation to bear the "Core" i5/i7 branding. Older CPUs will crusade the finder to repeatedly crash afterward installation completes (with an Illegal Teaching exception in the graphics code).

Modernistic AMD CPUs besides back up SSE 4.2 and will work with this guide.

Showtime step: Create an installation ISO

The easiest installer to build is a recovery image, which volition download Catalina during installation. Download and run fetch-macOS.py in a terminal to download the Catalina recovery image from the Apple software distribution server (this can exist run on Linux, Proxmox, or on a Mac):

This results in a ~500MB "BaseSystem.dmg" file in the current directory. Catechumen that dmg into an "iso" like so if yous're building this on macOS:

hdiutil convert BaseSystem.dmg -format UDRW -o Catalina-installer.iso mv Catalina-installer.iso.img Catalina-installer.iso

Or similar and then if you're building this on Linux:

# Install the dmg2img package and... dmg2img BaseSystem.dmg Catalina-installer.iso  # Or use qemu-img from the qemu-utils bundle to exercise it instead: qemu-img convert BaseSystem.dmg -O raw Catalina-installer.iso

The issue is actually a raw deejay image, non a truthful ISO, but Proxmox has ameliorate tools for picking and re-using ISO images than deejay images. Upload the "ISO" to your Proxmox server'south ISO store (typically /var/lib/vz/template/iso).

If y'all won't accept an Internet connectedness available to Catalina during installation, or your network can't provide an IP address by DHCP y'all'll demand to build an offline installer instead. Building the offline installer requires you to accept a Mac, here are the instructions.

Prepare an OpenCore image

We'll be using OpenCore as a bootloader for Catalina. This has several improvements over my old Clover-based tutorial, like fixes to screen resolution problems, better CPU feature support, and ameliorate FileVault compatibility, and is recommended for all futurity builds.

Download the latest OpenCore.iso.gz release from my repository, unpack it, and upload information technology to Proxmox'southward ISO store at /var/lib/vz/template/iso. Although it has a .iso file extension, this is actually a hd epitome.

Fetch the OSK authentication key

macOS checks that it is running on real Mac hardware, and refuses to boot on third-party hardware. You can get effectually this past reading an authentication fundamental out of your real Mac hardware (the OSK primal). Save the first block of C code from this page every bit smc_read.c. In a control prompt, modify into the same directory every bit that file and run:

xcode-select --install # If y'all don't already have gcc gcc -o smc_read smc_read.c -framework IOKit ./smc_read

It'll print out the 64 character OSK for y'all. Make a note of information technology.

Every Mac uses the same OSK, and then don't be surprised that information technology doesn't look like a random string!

Create the VM

From the Proxmox web UI, create a new virtual machine equally shown below.

In the Options page for the VM, ensure that "apply tablet for pointer" is gear up to "Yes".

In the Hardware page for the VM, add a 2d DVD drive at IDE0, set it to use your Catalina-installer.iso.

Don't try to start the VM just notwithstanding. First, SSH into your Proxmox server then we tin brand some edits to the configuration files.

Edit /etc/pve/qemu-server/YOUR-VM-ID-Here.conf (with nano or vim). Add this line, being sure to substitute the OSK you extracted earlier into the right identify:

args: -device isa-applesmc,osk="THE-OSK-You lot-EXTRACTED-GOES-HERE" -smbios blazon=ii -device usb-kbd,bus=ehci.0,port=2

(A USB keyboard is added here because macOS doesn't back up QEMU's default PS/2 keyboard.) Ensure the args are all on a single line!

Nosotros as well need to add together a -cpu argument. If your host CPU is Intel, add together this to the stop of the "args" line:

-cpu host,kvm=on,vendor=GenuineIntel,+kvm_pv_unhalt,+kvm_pv_eoi,+hypervisor,+invtsc

This volition pass through all of the features that your CPU supports. OpenCore's config volition pretend to macOS that the CPU'due south model proper name is Penryn for compatibility.

If your host CPU is AMD, or the above statement doesn't work for you lot, use this more-uniform culling:

-cpu Penryn,kvm=on,vendor=GenuineIntel,+kvm_pv_unhalt,+kvm_pv_eoi,+hypervisor,+invtsc,+pcid,+ssse3,+sse4.2,+popcnt,+avx,+avx2,+aes,+fma,+fma4,+bmi1,+bmi2,+xsave,+xsaveopt,bank check

This pretends that your CPU is Penryn, which will keep macOS happy even if your host CPU is AMD, and adds a agglomeration of newer required and optional CPU features on peak. Features that your host CPU doesn't support volition be ignored (a alarm will be printed to the console during launch with qm start 1xx), but note that macOS won't work without SSE4.2 support.

Now notice the lines that define the two "ISOs" (ide0 and ide2), and remove the ",media=cdrom" role from them. Add ",cache=unsafe" in its place. This will treat these as hard disks rather than DVD drives.

Save your changes, return to the Options tab, and modify the kicking order to put IDE2 (the OpenCore image) get-go. Your final VM configuration file should resemble this:

args: -device isa-applesmc,osk="..." -smbios type=two -device usb-kbd,bus=ehci.0,port=2 -cpu host,kvm=on,vendor=GenuineIntel,+kvm_pv_unhalt,+kvm_pv_eoi,+hypervisor,+invtsc balloon: 0 bios: ovmf bootdisk: ide2 cores: 4 cpu: Penryn efidisk0: vms:vm-100-disk-1,size=1M ide0: isos:iso/Catalina-installer.iso,cache=unsafe,size=2094688K ide2: isos:iso/OpenCore.iso,cache=unsafe,size=150M machine: q35 memory: 4096 name: catalina net0: vmxnet3=...,bridge=vmbr0,firewall=1 numa: 0 ostype: other sata0: vms:vm-100-deejay-0,enshroud=dangerous,discard=on,size=64G,ssd=1 scsihw: virtio-scsi-pci smbios1: uuid=... sockets: i vga: vmware

Configure Proxmox

On Proxmox, run "echo i > /sys/module/kvm/parameters/ignore_msrs" to avoid a bootloop during macOS kick. To make this change persist across Proxmox reboots, run:

echo "options kvm ignore_msrs=Y" >> /etc/modprobe.d/kvm.conf && update-initramfs -k all -u

Different Clover, OpenCore doesn't require Proxmox'south OVMF packet to exist patched, so if you had previously installed my pve-edk2-firmware parcel, and you don't have any Clover VMs left, you lot can revert to the vanilla Proxmox package past running "apt-marking unhold pve-edk2-firmware; apt install pve-edk2-firmware". If yous still accept Clover VMs that need information technology, yous tin continue to use my patched bundle, it'll piece of work too.

Install Catalina

Now get-go up your VM, it should kicking to the OpenCore kick picker:

OpenCore "OpenCanopy" boot menu

Printing enter to boot the "macOS Base System" entry and the installer should appear.

Our virtual hard drive needs to exist erased/formatted earlier nosotros can install to information technology, so select the Deejay Utility selection. Follow the steps below to format the disk:

Now we're gear up to begin installation!

Later the first phase of installation, the VM will reboot. Option the "macOS Installer" entry to go on installation:

The VM volition finish installation and reboot itself a second time. At present the installation is complete, and so choose the name of your main disk to boot (mine's called Master):

Answer the initial install questions, and you'll exist logged on! (Notation that you'll want to agree off on logging into your iCloud account until you've configured your SMBIOS to your liking)

Information technology works!

Make the OpenCore install permanent

We're currently booting using OpenCore from the attached OpenCore ISO. Allow's install that to the difficult drive instead. Pop open Terminal and run "diskutil listing" to see what drives we have available.

Employ "sudo dd if=<source> of=<dest>" to copy the "EFI" division from the OpenCore CD and overwrite the EFI partition on the hard disk. The OpenCore CD is the small disk (~150MB) that only has an EFI sectionalisation on it, and the main hard disk drive is the one with the large Apple_APFS "Container" sectionalization on it.

In my instance these EFI partitions concluded up existence called disk1s1 and disk2s1 respectively, so I ran "sudo dd if=/dev/disk1s1 of=/dev/disk2s1" (note that if y'all go these names wrong, you lot volition overwrite the incorrect disk and y'all'll have to beginning the installation over again!).

At present shut down the VM, and remove both the OpenCore and the Catalina installer drives from the Hardware tab. On the Options tab, edit the boot guild to place your SATA disk as the get-go disk. Kicking up. If everything went well, you should encounter the OpenCore kicking bill of fare, and you lot can select your "Main" disk to kick Catalina:

Sleep management

I found that I was unable to wake Catalina from sleep using my mouse or keyboard. If yous come across the same trouble, you tin either disable system sleep in Catalina's Energy Saver settings to avoid the issue, or you tin manually wake the VM up from slumber from Proxmox by running:

qm monitor YOUR-VM-ID-HERE            
system_wakeup
quit

Editing your OpenCore/EFI settings

The Configuration.pdf that explains the OpenCore config.plist file tin be found forth with the OpenCore release on my GitHub.

To mountain your EFI sectionalization in macOS so you lot can edit config.plist, beginning check the "identifier" of your EFI partition in the terminal:

~$ diskutil listing /dev/disk0 (external, physical):    #:                   Blazon Proper name              SIZE       IDENTIFIER    0:  GUID_partition_scheme                  *512.1 GB   disk0    1:                    EFI EFI               209.seven MB   disk0s1    ii:             Apple_APFS Container disk1   511.9 GB   disk0s2          

Then y'all tin mount it similar so:

sudo mkdir /Volumes/EFI
sudo mount -t msdos /dev/disk0s1 /Volumes/EFI

At present you tin can edit /Volumes/EFI/OC/config.plist with your favourite text editor to make your changes. (TextEdit is not a cracking choice because it likes to insert curly quotes into the file and otherwise break things, there are some dedicated plist editors bachelor such every bit XCode).

If you lot're unable to boot macOS, you can edit the config.plist using the "UEFI Shell" option in the OpenCore boot carte du jour instead.

Enter "FS0:" and printing enter to open up the first available filesystem, and so run "edit EFI\OC\config.plist" (if the file isn't found, try switching to another filesystem similar fs1:). When you're done editing, press control+Q to exit, "Y" to save, then run "get out" to return to the OpenCore menu. You need to reboot for your changes to have effect.

Automatic kick

In config.plist, set Misc/Boot/Timeout to a non-zero value to let the default boot option be called automatically later on that delay in seconds. I've disabled this by default because it causes the installer ISO to re-enter its master bill of fare instead of standing the second phase of installation.

Verbose kicking

To boot macOS in Verbose fashion to diagnose kicking problems, edit config.plist to modify the "bootargs" in the NVRam department from "keepsyms=1" to "keepsyms=one -v".

Changing screen resolution

To change macOS' screen resolution, y'all need to edit the UEFI/Output/Resolution setting in config.plist, the default is 1920×1080@32.

You lot should exist able to change this to whatsoever of the modes that the system OVMF menu offers (hit F2 at the start of guest kicking and choose "Device Manager/OVMF Platform Configuration" to run into which resolutions are available).

Video performance

Because there is no invitee video acceleration bachelor for macOS, video functioning is poor.

In Google Chrome in the guest yous will need to toggle off the setting to "use hardware dispatch when available" to meliorate problems with elements not being drawn or flickering (particularly video). Safari may be a better pick.

macOS's built in "Screen Sharing" feature offers dramatically ameliorate framerates and latency than Proxmox's browser-based VNC console, so if y'all have a real Mac to human activity equally a viewing panel, you tin can enable that in the VM's "Sharing" settings and connect to the VM using the Screen Sharing app from your Mac instead:

Evidently Screen Sharing is too compatible with VNC clients like RealVNC, and then you should be able to connect to it from Linux or Windows consoles using RealVNC.

The real magic bullet for video performance is to pass through a compatible video card using PCIe passthrough (though annotation that Catalina does not support most NVidia cards). This offers near-native performance. You can read more about how I'm using PCIe passthrough on my ain installation here.

USB passthrough

Since I want to use this every bit my primary computer, I desire to use a USB keyboard and mouse plugged direct into Proxmox, rather than sending my input through the web VNC panel.

Proxmox has proficient documentation for USB passthrough. Basically, run "qm monitor YOUR-VM-ID-HERE", then "info usbhost" to get a list of the USB devices connected to Proxmox:

qm> info usbhost
Bus 3, Addr 12, Port 6, Speed 480 Mb/s
Class 00: USB device 8564:yard, Mass Storage Device
Bus 3, Addr xi, Port 5.four, Speed 12 Mb/s
Class 00: USB device 04d9:0141, USB Keyboard
Omnibus 3, Addr 10, Port 5.i.2, Speed 12 Mb/s
Form 00: USB device 046d:c52b, USB Receiver
Autobus 3, Addr 9, Port 14.4, Speed 12 Mb/s
Grade 00: USB device 046d:c227, G15 GamePanel LCD
Coach three, Addr 8, Port 14.1, Speed i.5 Mb/s
Form 00: USB device 046d:c226, G15 Gaming Keyboard

In this example I can add together my keyboard and mouse to USB passthrough by quitting qm, then running:

qm set YOUR-VM-ID-Hither -usb1 host=04d9:0141
qm set YOUR-VM-ID-Hither -usb2 host=046d:c52b

This saves the devices to the VM configuration for yous. Y'all need to reboot to accept the new settings apply. Notation that the emulated USB3 device doesn't work with macOS, then don't gear up "usb3=1".

You lot can likewise pass through USB devices by passing through an entire USB controller using Proxmox's PCIe passthrough feature, which gives much better compatibility.

FileVault

FileVault login prompt

FileVault at present works with OpenCore, so you can encrypt your boot disk by using the pick in macOS' system security preferences. Just be sure to keep a copy of your recovery key and keep your backups up to date.

Using an odd number of CPU cores

macOS doesn't like it if your CPU has a weird number of cores, similar 3 or 6. You can fix this on the Hardware tab. Edit the Processors settings, and tick the Avant-garde box. Circular upwards the number of cores yous want (e.one thousand. 3) to a overnice ability of two (4, 8, xvi, etc) and use that for the "Cores" setting, but set the "VCPUs" setting to the number of cores you really desire to be used (iii), like so:

This will crusade macOS to come across that arrangement supports a maximum of four cores, just that one core is absent since it hasn't been hotplugged yet, and then macOS volition only apply iii cores.

Another approach is to use an odd number of sockets in order to make the cadre count a power of two. e.g. to pass 6 cores, set Sockets to 3, and Cores to ii (or iv to pass both threads per cadre).

Proxmox doesn't let us fix the number of threads per core in the VM config, so if y'all want to pass every thread of a hyperthreaded 6-core CPU, and have them reported to the guest every bit hyperthreads, add -smp 12,sockets=three,cores=2,threads=2 to your "args", or for a 56-core hyperthreaded CPU, -smp 112,sockets=vii,cores=8,threads=two.

Nested emulation

If your host CPU is Intel, and yous used "-cpu host" in your VM config file (explained to a higher place), you lot can apply Nested Virtualisation in macOS. This allows you to run VirtualBox VMs, the Android emulator, or Docker inside your macOS invitee. You just need to tweak your Proxmox arrangement config to enable this as explained in the Wiki:

https://pve.proxmox.com/wiki/Nested_Virtualization

macOS'due south Hypervisor framework doesn't support nested virtualisation on AMD host CPUs, but apparently VirtualBox uses their own virtual machine driver which does work (I haven't tried this myself). I imagine this will stop working in the next version of macOS, since they're planning to add a bunch of restrictions on third-party kexts and might force VirtualBox to utilize Hypervisor.framework.

Getting iMessage and FaceTime to work

Unlike the App Store and iCloud, these Apple services actually pay attention to your Mac's serial number.

Following this guide should become these working for y'all:

https://dortania.github.io/OpenCore-Mail-Install/universal/iservices.html#generate-a-new-series

I had already generated a series number for my Mac (when I bank check the Support Status for it, it says "Nosotros're lamentable, but this serial number isn't valid. Please bank check your information and endeavour over again") and added it to my OpenCore config, then all I had to do on top of that was use Hackintool to assist me mark my Ethernet adapter en0 as built-in. FaceTime then worked immediately. I didn't need to follow the rest of the guide.

Fixing "invitee boots to UEFI shell"

If your guest ends up booting to the UEFI shell instead of showing the OpenCore boot menu, particularly if yous've just updated OpenCore to a new version, yous'll demand to edit the guest's UEFI boot entries to fix this.

At the very start of invitee boot, hit F2 to enter guest UEFI settings.

First we'll remove the old entries. Choose the Boot Maintenance option, and then Kick Options -> Delete Boot Option. Use the spacebar to tick any onetime Clover or OpenCore entries (avert ticking the EFI Internal Beat option, you lot want to keep that!). Select "Commit Changes and Get out".

Now we'll add the right entry for OpenCore back in. Select Add together Boot Option. Navigate through the device tree to EFI/BOOT/BOOTx64.efi and select it, name this new option "OpenCore" or similar. Again Commit Changes and Exit.

Get to the Modify Kicking Club and move OpenCore to the height. Commit Changes and Exit.

At present dorsum out to the main menu and choose Reset, and you should successfully boot into OpenCore this time.

marcumhistailley.blogspot.com

Source: https://www.nicksherlock.com/2020/04/installing-macos-catalina-on-proxmox-with-opencore/

0 Response to "osx dropbox continue upload when monitor sleep"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel