*********** To the admins and or developers of unity ************ could you please pass on a small message, It seems as though this solution is working for a few people. If your team was to automate this solution through the self deployment I am more then sure this issue would disappear. Some times the npm registry could be down or machines might muck something up but if its done locally its one less thing to worry about. ************************************************************************* *** Thank you to malyzeli as he had the one liner idea ***
For anyone getting the grey screen after install I have figured out how to fix it. (This is with Ubuntu other distros may vary slightly.)
Method A.) Visual one liner (myself: visuals / wildcard and malyzeli original one liner**)**
Method A: 1.) Create a folder called unityfix in /Home/Downloads 2.) Place the unity(someversion).deb file into unityfix folder 3.) Open terminal copy paste the below
cd ~/Downloads/unityfix && unityfile=$(stat -t *.deb --format=%n) && echo âplease be patient extracting .deb fileâ && ar x $unityfile && echo âextracting data from tarballsâ && tar -zxvf data.tar.gz -C ~/.local/share/unity3d/ --strip-components=6 ./opt/Unity/Editor/Data/Resources/Packages && cd ~/.local/share/unity3d/Packages && ls | grep tgz | xargs npm i --verbose && echo âCompleteâ
once its finished it will say Complete you can now run unityâŚ
Explanation for people who are scared to enter strange code into terminal (you should be!):
unarchive (ar x) unity-editor.deb into actual directory (retrieving data.tar.gz and other stuff)
use tar to unzip (-z) and extract (-x) Packages from data.tar.gz (-f) into ~/.local/share/unity3d/ (-C), -v stands for verbose (you see whatâs going on in console) and --strip-components is there to get rid of full path in archive
change directory (cd) to ~/.local/share/unity3d/
list (ls) all files in directory and filter (grep) only tgz ones
pipe those files into xargs to call npm install on each of them
echo just prints the âtext in quotes to the screenâ
unityfile=$(stat -t *.deb --format=%n) its a wildcard so you dont have to know the filename $unityfile is the name that was found from the stat.
I had no idea that this would work. Honestly, I tried this as a last resort, because it seemed so ridiculous. I have no idea why I would have to run npm on those files manually⌠but hey, it worked!
@LevonRavel First of all thanks a lot for your solution!
Now letâs improve it a bit, since I was personally quite annoyed by having to open three different pictures, examine them, read and write and click a lot of thingsâŚ
So my step-by-step automated solution is this:
get the Unity installer .deb and note the filename, youâll need it in next step (lets say I saved it as unity-editor.deb)
open terminal in directory where that file is and enter this one-liner do it for you (replace unity-editor.deb by the corresponding filename)
ar x unity-editor.deb && tar -zxvf data.tar.gz -C ~/.local/share/unity3d/ --strip-components=6 ./opt/Unity/Editor/Data/Resources/Packages && cd ~/.local/share/unity3d/Packages && ls | grep tgz | xargs npm install
Wait for a while, since opening >2GB archive can take couple of minutes on slower machines.
When terminal returns to command prompt, you are ready to launch Unity!
Now you can also safely remove files unarchived from deb (data.tar.gz, control.tar.gz and debian-binary).
Explanation for people who are scared to enter strange code into terminal (you should be!):
unarchive (ar x) unity-editor.deb into actual directory (retrieving data.tar.gz and other stuff)
use tar to unzip (-z) and extract (-x) Packages from data.tar.gz (-f) into ~/.local/share/unity3d/ (-C), -v stands for verbose (you see whatâs going on in console) and --strip-components is there to get rid of full path in archive
change directory (cd) to ~/.local/share/unity3d/
list (ls) all files in directory and filter (grep) only tgz ones
pipe those files into xargs to call npm install on each of them
Method B, it looks like the packageâs download page is bringing a 404 not found error. Hereâs npmâs output.
npm info trying registry request attempt 1 at 00:02:11
npm http GET https://registry.npmjs.org/unityeditor-cloud-hub
npm http 404 https://registry.npmjs.org/unityeditor-collab-history
npm http 404 https://registry.npmjs.org/unity-editor-home
npm ERR! 404 Not Found
npm ERR! 404
npm ERR! 404 'unityeditor-collab-history' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it
npm ERR! 404 It was specified as a dependency of 'unity-editor'
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, or http url, or git url.
npm ERR! System Linux 3.16.0-4-amd64
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "i" "--verbose"
npm ERR! cwd /opt/Unity/Editor/Data/Resources/Packages
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.21
npm ERR! code E404
npm verb exit [ 1, true ]
npm http 404 https://registry.npmjs.org/unityeditor-collab-toolbar
npm http 404 https://registry.npmjs.org/unityeditor-cloud-hub
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /opt/Unity/Editor/Data/Resources/Packages/npm-debug.log
npm ERR! not ok code 0
I just wanted to say⌠When I posted that I was getting it to run in ubuntu, and now I used the same fix to get Unity3D running on mint as well. Thank you!
Solves my blank screen problem. Iâm using Debian 8 âJessieâ, amd64. Version Unity 5.6.0xb3
Both the script and deb file extract the files within Editor/Data/Resources/Packages. The last step needed is installing them.
@FrostVoxel Yes, it works for the .sh file. They forgot to run a script to install the nodejs packages. You should run Method A after installation with .deb or extraction with the .sh files.
Iâm looking into a way to modify the script to make it work. Open the .sh installation script with vim. Itâs a file with a script at the top and an archive file appended at the bottom. It appears you can add Method A to the script. Bold lines indicates where to add new code. Itâs around line 61. DO NOT USE, BUGGY. The problem is that when the installation script is executed as root, it will copy the files into the rootâs home directory instead of the userâs home directory. Iâll come back to see what I can do to fix the installation script.
ARCHIVE=`awk '/^__ARCHIVE_BEGINS_HERE__/ {print NR + 1; exit 0; }' $0`
# Actual extraction
echo "Unpacking Unity 5.6.0xb3Linux ..."
mkdir -p "${EXTRACT_DIRECTORY}"
tail -n+${ARCHIVE} $0 | tar xj -C "${EXTRACT_DIRECTORY}"
# chrome-sandbox requires this: https://code.google.com/p/chromium/wiki/LinuxSUIDSandbox
chown root "${EXTRACT_SUBDIR}/Editor/chrome-sandbox"
chmod 4755 "${EXTRACT_SUBDIR}/Editor/chrome-sandbox"
echo "METHOD A GOES HERE"
cp "${EXTRACT_SUBDIR}/Editor/Data/Resources/Packages/*" ~/.local/share/unity3d/Packages
ls ~/.local/share/unity3d/Packages | grep tgz | xargs npm i
echo "Extraction complete. Run ${EXTRACT_SUBDIR}/Editor/Unity to begin"
exit
__ARCHIVE_BEGINS_HERE__
For the Deb File, you can add the following into the postinst file. I havenât tested it yet.
echo "METHOD A GOES HERE"
cp opt/Unity/Editor/Data/Resources/Packages/* ~/.local/share/unity3d/Packages
ls ~/.local/share/unity3d/Packages | grep tgz | xargs npm i
thank you sooo freaking much man I have been using rider with unity on linux but i dont like it as much as monodevelop seems as though rider taps into monos debugger anyhow⌠In any case thank you for helping with monodevelop such a freaking blessingâŚ