Drag and drop & copy/paste not working

Discussions related to using VirtualBox on Mac OS X hosts.
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

Paul, you're a damn fine gent, thank you.

Interesting stuff!

Ok It looks like a reinstall is needed. But before I do that, I should point out...

When I created this second user on my iMac I selected "Administrator" as it's access level/authority. I want both my users to be admins. I therefore assumed (naturally) that this user would have the same priveleges as the first account, i.e. "administrator". Thus I changed some of the permissions on VB files/folders by adding "administrators" = read/write. I assumed this user would therefore apply under that group.

But I just ran through the sysprefs/user groups procedure and here is what i found https://ibb.co/WvNLfS2
That's rather annoying, never heard of "staff", and never selected that!
I haven't edited anything in there (closed it) but do you think I could change that from staff to administrators? Or will that cause other problems? I can't see why it would, as the authority has only gone up!
Thanks again, so kind of you to help
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

By the way, just in case it's any use...

I don't have a lot of expertise with terminal and code, but I found a really neat workaround for finding all files related to an app, rather than guessing or (as was my approach) trawling through every single system folder one by one, very time consuming!

I installed an app called AppCleaner (from freemacsoft i think). That app cleanly and fully uninstalls apps for you. You drag an app onto the AppCleaner app icon and it pops up a dialogue asking for confirmation before deleting files. It's damn thorough, it catches everything. But what I found is it's a great tool for finding all remnants/files related to an app, you don't have to remove them or uninstall! There are more files for VB than I thought, I will check permissions on all of them.
Here's a screenshot https://ibb.co/HtxyqBC
Note the magnifying glass, so you can click to open each file one by one. Very nice trick for someone lacking in depth knowledge of file structures/terminal etc, like me! And yes I know with great power comes great responsibility :D
paulmc
Posts: 72
Joined: 28. Aug 2019, 18:43
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Mac OS X, Linux, Windows
Location: Earth (Guyana / USA / South Africa)
Contact:

Re: Drag and drop & copy/paste not working

Post by paulmc »

@sudokillall, in Unix-based systems, a user has a "primary" group but can also be a member of other groups. So, typically there's no need to change the primary group. Each group has an associated list of member users, and that's one way the system can know who's in which group and has which privileges. {There are actually multiple ways to establish membership, e.g., via special 'catch-all' groups, etc.} In macOS, it's normal for a user to have 'staff' as their primary group. An admin-level user would also be assigned membership in the 'admin' group, and so on. In a Terminal window you can run the command 'id' without any options, to see more information about your user account including a surprisingly long list of all groups to which you belong. {If you're interested in diving further, there are several good sources available online that discuss various aspects of ownership/permissions.}

As to the AppCleaner utility, in general it looks like a fairly useful way to see the items associated with a given program, and/or to remove any unexpectedly lingering preferences, etc. However, note that AppCleaner can't know about every item associated with every program, and likely makes use of various heuristics such as "educated guesses" based on name or bundle identifier, which could end up missing certain items/settings. For instance, if a program or installer also places arbitrarily-named dynamic libraries into '/usr/local/lib/', etc., then those might not get detected; and, likewise for any special configuration changes made to system databases or plists. So, when a dedicated uninstaller is provided with a given program, especially if it's a complex & powerful one such as VirtualBox, it's usually a good idea to use that official uninstaller instead. E.g., you could do something similar to a thorough uninstall-&-reinstall procedure for VirtualBox Mac as outlined by former moderator socratis.
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

Thanks again. Very interesting (id command). yes my user is in staff, everyone, admin etc.

Re AppCleaner - Yes for something like VB I would always use the official uninstaller (didn't know there was one actually!) but I do use AppCleaner sometimes, mainly to test for privacy reasons. I have installed various apps (recent example was NoMachine, YUK, don't touch it!) and when uninstalling it left no end of remnants in my system and LittleSnitch even caught one or two processes calling home despite the entire app 'allegedly' having been removed! Sadly this is pretty common these days so I do all sorts of weird stuff to satisfy my paranoia :)
But obviously that doesn't apply to VB or many other apps, though I do use AppCleaner to find files sometimes related to apps.

So... time to uninstall VB and see if a reinstall sorts it. If not I will be stumped. I am away tomorrow for a few days so I will leave it til i get home so I can focus and finish the job. I will read through that thread carefully before i begin.
Quick question if I may - Can you tell me which folders/files I would need to keep (or MOVE perhaps) to protect from my actual guest OS/VM being removed by uninstallation? I assume that Virtualbox VM's folder is the one, but does that contain the entire VM OS? If so I will make sure i have a second backup of that.
Very grateful for your help, again :)
paulmc
Posts: 72
Joined: 28. Aug 2019, 18:43
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Mac OS X, Linux, Windows
Location: Earth (Guyana / USA / South Africa)
Contact:

Re: Drag and drop & copy/paste not working

Post by paulmc »

@sudokillall, in terms of your guest VMs, even a thorough uninstall won't remove those so they'll be left intact. Traditionally, an uninstaller for a given program tends not to touch any documents a user has created via that program, and in a sense the guest VMs are VirtualBox's "documents".

For extra peace of mind though, you could first make a backup copy of the entire guest VMs folder located as per the VirtualBox manager's Preferences > General => 'Default Machine Folder:' setting {typically '/Users/<your_user>/VirtualBox VMs'}.
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

Excellent thanks. Will let you know if I survive!
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

Hi again Paul, I am home and dry, about to try the uninstallation.
I was just reading back to refresh my memory on your excellent advice here, I noticed your forum profile says you have VMs running on Linux, Windows and MacOSX! I didn't even know you could run a virtual session of MacOSX! That got me thinking, and i wondered if you had any thoughts as you clearly know your stuff...

I am heavily into privacy. Without boring you as to the reasons why, I distrust apple much more than I used to. I have reason, not paranoia, including friends in a position to know certain things most of us aren't. One of those friends reliably informs me that Apple stores a LOT of data on users, hence why they agreed with China's CCP to store all Chinese user's data (in particular encryption keys and keychain/icloud data) on servers physically located in China, where they can be got at quite easily with a warrant, where warrants in China can be scribbled out by a Police Officer and executed without so much as a nod from another party (i.e. a judge). Ever since Catalina (which I have never used), which saw the beginnings of what are in my view Apple's moves much more towards the Windows model of storing as much data on users as possible, although in apple's case making that ONLY available to Apple (and govt debatably) rather than tons of 3rd party advertisers and purchasers, I have sought to protect myself more and more from the huge amount of connections and data transmissions from OSX to Apple servers (and others). Then came Big Slur and once I looked into that, I have sadly decided to slowly move to Linux. By the time my OSX (Mojave) is no longer supported, I expect to be using Linux full time. But that's a big ask for me, not being a dev type!

I have run Little Snitch for many years, just to avoid spyware and unwanted connections from installed programs, checking for updates, reporting my location, habits, browsing history etc etc. But recently I have begun to try to use it to block as many Apple connections as possible too. I don't use icloud, apple email addresses, maps, itunes store, photo sharing, cloud backups, find my mac, or anything else I can easily avoid using open source alternatives where needed. I also don't store any passwords in icloud/keychain. I found with Mojave they made a sneaky move which, whilst I am technical enough to be able to fully confirm, I feel quite sure just from my testing, that Apple are storing disk encryption passwords. Of course they offer to do that for convenience, such as storing in online keychain. But I don't want them storing it, and that was never a problem with High Sierra or prior, but since Mojave a restore to a new machine turns off filevault, forcing users to encrypt their data AFTER setting up the user account. Having researched a lot of what goes on in China (with Apple especially), I BELIEVE this is a neat trick to push people into entering their disk encryption key AFTER logging in, rather than before, thus making it available to Apple. I am sure many will not believe this, and I am not looking to debate it, and of course it may not be the case. But I am at this point quite convinced that they do so.

For my last restore I found a way around it, but it won't be around much longer. I keep clones and TM backups, but I also keep a clone of my last High Sierra clone. I found that I can use that to clone to any mac (newer ones for instance), then manually migrate the rest of my data from more recent (Mojave) clones/backups. By doing it that way, the HS install/restore can be done on a HDD which is manually encrypted during formatting, AND the restore doesn't turn it off (turning FileVault off). So for instance my machine I am using here now, when I power it on or restart, it asks for a disk encryption key BEFORE any users are anywhere near loaded. It takes a fair while (5 minutes just to decrypt and offer logins), but I THINK that means my encryption key isn't ABLE to be passed to apple even if they are doing anything like that. It's extemely hard to explain exactly what I mean, but I spent 1-2 WEEKS solid, cloning and restoring, using different versions of OSX, and I am fairly sure I both found the 'trick' going on, and a way to avoid it. I could of course be wrong, but since I believe this, I will continue as if it's true :)

I have noticed my Mac is running slower than it should, especially after boot up. I am wondering if this is because loads of processes are running (hammering the CPU usage in ActMon) but Little Snitch is blocking the connections, meaning the processes hammer my machine much longer than they normally would if they had the connections they want to Apple. The problem is that Apple is deliberately making things difficult, and that's in Mojave. It's pretty much impossible in Big Sur. For instance they tie processes to more than one purpose, so if you want to block one thing (for instance iTunes store, or PhotoLibrary "analysis") it will also block something else which can't be blocked without harming the running of the OS, for instance Gatekeeper checks. In other examples the servers you have to block are needed for both essential things, AND spurious privacy invasive things which I want to block but can't.

So, long story short... I found this - https://gist.github.com/pwnsdx/1217727c ... fdd7a0fc21

I am not quite confident enough with Terminal to run it, and that really bugs me as I would love to try it but my machine is used for business stuff and a lot of personal stuff too, so I can't chance it in case I do something wrong. Which leads me to the beginning! If you can run OSX in a VM, maybe that would be a neat way to play around and see how the OS runs with that script blocking all those nasties!!

Do you have any knowledge of that script, or of blocking any of these processes it blocks, manually like that? I don't even know how to run it, github is designed for people who understand not only code, but github itself too! I understand neither! I have used Terminal a fair bit, but not confidently!
I have installers for the last 6 or 7 Apple OSX versions (except Big Slur as I don't even want the installer for that :D), is it just a case of starting a new VM and running one of those, and then I will have Mac OSX inside Max OSX? If so, great! I will have to give that a whirl!!

Thanks again for all your help above. I am off to try and uninstall VB and reinstall :)
sudokillall
Posts: 36
Joined: 13. Feb 2021, 07:01

Re: Drag and drop & copy/paste not working

Post by sudokillall »

Repeated all steps over and over and as if by magic, VB finally installed properly and now working again :)
paulmc
Posts: 72
Joined: 28. Aug 2019, 18:43
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Mac OS X, Linux, Windows
Location: Earth (Guyana / USA / South Africa)
Contact:

Re: Drag and drop & copy/paste not working

Post by paulmc »

@sudokillall, first my apologies for this delayed reply {I got tied up with a work project} …

Well, I'm really glad that you were able to reinstall VirtualBox successfully! :-)

As to the Apple / macOS security & tracking concerns, I hear you. It seems that nowadays lots of folks share these misgivings about various platforms, including: proprietary operating systems; corporate & other websites; social media; etc.

I'm not familiar with that 'disable.sh' script per se, although in general such script files {assuming that the appropriate 'execute bit' permission is set} can indeed be run via a Terminal window. For specific assistance with its disabling of various OS services, etc., please do continue to reach out to the author on GitHub.

In addition, if you still wish to set up a macOS guest VM to experiment with it, then a good place to start would be the 'Mac OS X Guests' forum, including the "sticky" threads listed at the top — especially '[HowTo] Create OSX ISO from the OSX Install app' which discusses one way to convert Apple's macOS Installer apps into disk-image / ISO files, via either former moderator @socratis' command-line script or @granada29's GUI app wrapper for that script. {Also, for a macOS 10.13 High Sierra guest installation, note that the lower-level EFI menu workarounds described in '[HowTo] Install OSX 10.13 in a VM' are no longer necessary as of VirtualBox 6.1.x.}
Post Reply