I just installed the VMware Workstation Player virtual machine on my laptop running Ubuntu. On the final step of installation, I get the error message "Version mismatch with vmmon module: expecting 360.0, got 309.0.
You have an incorrect version of the 'vmmon' kernel module" Does anyone know how to fix this?
The below technique manually rewrites vmmon and is from a vmware forum (and other places). This worked well for me for my Ubuntu 18.04 guest on a MacOS host.
Quit Fusion.
In terminal:
sudo rm -rf /System/Library/Extensions/vmmon.kext
sudo cp -pR /Applications/VMware\ Fusion.app/Contents/Library/kexts/vmmon.kext /System/Library/Extensions/
sudo kextunload /System/Library/Extensions/vmmon.kext
sudo kextutil /System/Library/Extensions/vmmon.kext
VMWare should restart correctly with the new version.
Related
I have a new M1 pro macbook and I'm trying to install pyodbc and relevant drivers on my machine.
So far I have installed unixodbc via homebrew and ODBC drivers according to the instructions found here: https://learn.microsoft.com/en-us/sql/connect/odbc/linux-mac/install-microsoft-odbc-driver-sql-server-macos?view=sql-server-ver15https://learn.microsoft.com/en-us/sql/connect/odbc/linux-mac/install-microsoft-odbc-driver-sql-server-macos?view=sql-server-ver15
I then pip installed pyodbc but when I try to run pyodbc.connect() within a test script, python just aborts with the following message, regardless which connection string I use:
[1] 2086 abort python test.py
After investigating a bit more I find that pyodbc doesn't have any drivers. When I run pyodbc.drivers() I get an empty list. So it seems like pyodbc cannot find the drivers I installed earlier.
Here is the output when I run odbcinst -j:
unixODBC 2.3.9
DRIVERS............: /opt/homebrew/etc/odbcinst.ini
SYSTEM DATA SOURCES: /opt/homebrew/etc/odbc.ini
FILE DATA SOURCES..: /opt/homebrew/etc/ODBCDataSources
USER DATA SOURCES..: /Users/kdot/.odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8
and the odbcinst.ini file contains:
[ODBC Driver 17 for SQL Server]
Description=Microsoft ODBC Driver 17 for SQL Server
Driver=/opt/homebrew/lib/libmsodbcsql.17.dylib
UsageCount=3
I've also tried to explicitly give the driver file path to pyodbc in the connection string but then pyodbc.connect() just hangs instead of aborting right away.
I am running all of this within a virtual environment with the following versions:
python: 3.8.10
pyodbc: 4.0.32
Does anyone know how to make pyodbc see and use the relevant drivers?
First, install the ODBC driver as instructed by Microsoft here.
Further, Microsoft recommends creating symbolic links as follows:
sudo ln -s /usr/local/etc/odbcinst.ini /etc/odbcinst.ini
sudo ln -s /usr/local/etc/odbc.ini /etc/odbc.ini
However, the location of those files on M1 macs might be different, depending on the the default homebrew directory. In my case, the following paths worked:
sudo ln -s /opt/homebrew/etc/odbcinst.ini /etc/odbcinst.ini
sudo ln -s /opt/homebrew/etc/odbc.ini /etc/odbc.ini
This is what worked for me on a m2 macbook (from the official ms documentation).
Make sure you have homebrew installed.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
brew tap microsoft/mssql-release https://github.com/Microsoft/homebrew-mssql-release
brew update
HOMEBREW_ACCEPT_EULA=Y brew install msodbcsql17 mssql-tools
sudo ln -s /opt/homebrew/etc/odbcinst.ini /etc/odbcinst.ini
sudo ln -s /opt/homebrew/etc/odbc.ini /etc/odbc.ini
The problem here is that "several critical CLI tools like nvm and brew do not have native versions built for the new M1 architecture." Source.
Luckily Apple Silicon comes with a translation layer named Rosetta 2, which is basically a CLI interface through which you have to install tools like brew in order for them to install correctly.
In this Medium post you can read how to use Rosetta 2. We got pyodbc working by installing Python 3.9, pip, wheel, openssl, unixodbc, freetds, the correct drivers and finally pyodbc (in this order) all with Rosetta 2.
Found the following link helpful to install pyodbc on MacBook M1 Chip.
We happen to get sql.h file missing error and if we try to install the wheel directly from the site it throws platform not supported error.
Follow the below document and then add the export commands into your zrc or bash file and you should be good to go.
https://whodeenie.medium.com/installing-pyodbc-and-unixodbc-for-apple-silicon-8e238ed7f216
Need more reading about the bug and how people tried to learn it.
https://github.com/mkleehammer/pyodbc/issues/846
I still had this issue with the default Homebrew & ODBC installations on macOS Ventura with a 2022 MacBook Pro.
The only thing that worked was to completely uninstall Homebrew and the ODBC drivers and then reinstall both with the prefix arch -x86_64.
$ arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
$ arch -x86_64 brew install msodbcsql18 mssql-tools18
I have a running system with Ubuntu 16.04, Apache 2.4.18, PHP 7.3 and 7.4, PHP-FPM, PHP FastCGI, MPM event.
I wanted to upgrade to the latest Apache version (2.4.46-2+ubuntu16.04.1+deb.sury.org+3 amd64 [upgradable from: 2.4.18-2ubuntu3.17]) as follows:
add-apt-repository -y ppa:ondrej/apache2
apt update
apt-get --only-upgrade install apache2
service apache2 restart
Job for apache2.service failed because the control process exited with error code. See "systemctl status apache2.service" and "journalctl -xe" for details.
journalctl -xe
apachectl[9010]: [:crit] [pid 9013] (38)Function not implemented: AH00141: Could not initialize random number generator
I checked and /dev/random and /dev/urandom are installed.
Kernel: 4.4.0-042stab141.2 and libc6: 2.23-0ubuntu11.2
Happened to me after upgrading apache to version 2.4.46 on Ubuntu as well. I found out it was the kernel version.
I knew I did apt-get upgrade and the kernel should be latest version, Also running
sudo update-grub
Showed me newer versions, but running uname -r showed very old kernel.
After a long investigation that took almost all day and trying everything I found online about upgrading Ubuntu kernel - I found out it was Digitalocean, not me. Old droplets use external managed kernel - so no matter what you do on your environment, it will always take the external kernel. The solution was here:
https://www.digitalocean.com/docs/droplets/how-to/kernel/grubloader/#switch
If you do see the drop down & change button in your droplet settings in Digital ocean control panel, then your kernel is externally managed. In that drop down type “grub” and choose GrubLoader v0.2, press “change” button & that’s it!
Now you’ll need to shut down & turn back on your server, but before you do so I suggest to run the following commands:
sudo apt-get update
sudo apt-get upgrade
The above upgrade will update the whole system. To update just kernel run the above update command followed by:
sudo apt-get upgrade linux-image-generic
Now shut down (sudo poweroff or power off from DigitalOcean interface, though doing it from CLI is preferred). Note that reboot is not sufficient in this particular case and a complete shut down is needed (Thanks #gauss256 for your comment). Then power it back on from digital ocean interface, And upon startup you should see a new kernel version.
Tip - you might want to delete old Kernel files after the reboot, this can be done by:
sudo apt-get purge $( dpkg --list | grep -P -o "linux-image-\d\S+" | grep -v $(uname -r | grep -P -o ".+\d") )
Trying to get up my VPN interface with sudo wg-quick down wg0;sudo wg-quick up wg0 raised:
RTNETLINK answers: Operation not supported
Unable to access interface: Protocol not supported
I am not sure what happened but the only thing I did was reboot. I did not update my packages. Still something apparently changed.
In my case there were no appropriate kernel headers installed.
First you need to know your current kernel version:
# uname --kernel-release
4.19.0-14-cloud-amd64
Important part here is "cloud-amd64" (there are several versions of "linux-headers-..." package, use apt list linux-headers-* to see what is available).
Then install appropriate kernel headers (I'm using Debian):
# apt install linux-headers-cloud-amd64
Then re-install wireguard-dkms package:
# apt install --reinstall wireguard-dkms
Reboot your OS:
# reboot
In my case (Debian 10, PiVPN) i had to:
Install linux headers:
apt-get update
apt-get install linux-image-amd64 linux-headers-amd64
reboot
apt reinstall wireguard-dkms
reboot
Running apt update / upgrade revealed that there are wireguard updates available. Install those (you might have to reboot as well) and all will work fine again.
Secure boot as the internet suggests was a false trail in my case.
solution can be simple:
set in
[Interface]
MTU = 1412
to avoid packet limitations.
Done.
You may elaborate a smaller fitting size.
In my case it was enough:
sudo apt update
sudo apt upgrade
sudo reboot
I just upgraded from Yosemite to El Capitan (and replicated the problem upgrading from El Capitan to Sierra), and when I try to type for example git status inside a terminal, I get the following error:
xcrun: error: invalid active developer path
(/Library/Developer/CommandLineTools), missing xcrun at:
/Library/Developer/CommandLineTools/usr/bin/xcrun
I don't have Xcode installed, never did.
Anyone have a solution?
Found the fix for the problem here.
xcode-select --install
This will bring up a prompt to install the necessary command line tools.
If you have issues with the xcode-select --install command; e.g. I kept getting a network problem timeout, then try downloading the dmg at developer.apple.com/downloads (Command line tools OS X 10.11) for Xcode 7.1
In macOS 10.14 this issue may also occur if you have two or more versions installed. If you like xCode GUI you can do it by going into preferences - CMD + ,, selecting Locations tab and choosing version of Command Line Tools. Please refer to the attached print screen.
I tried the solution xcode-select --install but it don't help me, I update from Sierra to High and happened this, my solution:
sudo xcode-select --reset
Reassigning the path Xcode is configured with worked for me.
sudo xcode-select -switch /Applications/Xcode.app
You'll then likely be prompted (after trying a command) to agree to the license agreement.
I had the same issue after upgrading to macOS Catalina.
This didn't work for me:
xcode-select --install
Downloading and installing Command Line Tools for Xcode 12 did it!
For me, after I've removed Xcode, I have to switch active developer path as follows:
sudo xcode-select -s /
I just updated to High Sierra and I couldn't just run xcode-select --install. First, I had to actually install xcode from the app store. Then I ran xcode-select --install. Then I had to run sudo xcodebuild -license, agree to the terms, then I could finally run git commands again.
Updated to High Sierra 10.13.2
xcode-select --install ALONE did not work for me.
Download X-code from app store
$xcode-select --install
a. May need to update after install using softwareupdate in command line. $sudo softwareupdate -i "Command Line Tools (macOS High Sierra version 10.13) for Xcode-9.1"
$sudo xcodebuild -license
For Mojave
Uninstall Any old version of Command Line Tools:
sudo rm -rf /Library/Developer/CommandLineTools
Download and Install Command Line Tools 10.14 Mojave.
For those also having issues with heroku command line tools after upgrading, I also had to do the following in my terminal:
xcode-select --install
brew install heroku/brew/heroku
brew link --overwrite heroku
It seems the upgrade to High Sierra messed with my symlinks in addition to forcing me to reinstall xcode tools. I kept getting 'not a directory' errors:
▸ stat /Users/mattymc/.local/share/heroku/client/bin/heroku: not a directory
▸ fork/exec /Users/mattmcinnis/.local/share/heroku/client/bin/heroku: not a directory
Hope that saves someone an hour :)
After update to macOS 10.13.3
After updating do macOS 10.13, I had to install
"Command Line Tools (macOS 10.13) for Xcode 9.3"
downloaded from https://developer.apple.com/download/more/
I upgraded mac os to macOS High Sierra - 10.13.3 and faced a similar issue while trying to install watchman (with command - brew install watchman).
ran the command: xcode-select --install, then ran "brew install watchman" - Everything works fine!
For the most recent version Mojave version 10.14.1, I use
solved by downloaded from https://developer.apple.com/download/more/ " login by apple id, and download
Command line tool newest stable version.dmg
That makes everything work
the old answer
xcode-select --install
doesn't work for me.
sudo xcode-select -s /Applications/Xcode-beta.app/Contents/Developer
Work for me.
Even if you do xcode-select --install it was not fixing that for me as it showed some network error. The problem was that it could not connect to the app store. I did the following to fix it.
Open keystore
Go to system root and select certificates.
Open digicert high assurance EV.
Expand the trust section, mark it as never trust.
Restart system now repeat step 1, 2, 3. and mark the trust policy as
back to use system defaults.
Your app store should work now and you should be able to run xcode-select --install
I need to monitor the performance of a raspberry PI (with raspbian), I tried to use new relic, but it doesn't support ARM architecture, so it's impossible to use.
I even tried graphdat but seems to have the same problem.
Any alternative to suggest me?
Linode Longview does support arm architecture:
https://www.linode.com/longview
The free tier have 12-hour retention but that may be enough for most cases.
I know this is old, but New Relic has ARM and ARM64 infrastructure agents now:
https://download.newrelic.com/infrastructure_agent/binaries/linux/arm/
I've tested this on a Raspberry Pi 4 (8GB) on Debian (32-bit) and it's been working fine so far.
In case anyone else tries, here's what I did:
Download the Infrastructure Agent:
sudo curl https://download.newrelic.com/infrastructure_agent/binaries/linux/arm/newrelic-infra_linux_1.20.5_arm.tar.gz --output newrelic-infra_linux_1.20.5_arm.tar.gz
Extract the files
sudo tar -xf newrelic-infra_linux_1.20.5_arm.tar.gz
Add license key to the config script:
echo "license_key=\"<YOUR_LICENSE_KEY>\"" | sudo tee -a ~/newrelic-infra/config_defaults.sh
Install the Infrastructure Agent
sudo ~/newrelic-infra/installer.sh
Check service status to make sure it's running:
sudo systemctl status newrelic-infra
By default, process information is not sent to New Relic, so I had to enable it manually:
echo "enable_process_metrics: true" | sudo tee -a /etc/newrelic-infra.yml
Finally, restart the service:
sudo systemctl restart newrelic-infra