Error: Bundler does not have write access to create a temp directory - ruby

When trying to run bundle install on a ruby project I received the following error:
There was an error while trying to write to `Bundler does not have write access
to create a temp directory within C:/Users/Simon/AppData/Local/Temp. Bundler
must have write access to your systems temp directory to function properly. `.
It is likely that you need to grant write permissions for that path.
I've checked the permissions in my temp folder and everything looks OK. Is there another possible cause of this error?

After much frustration, I discovered that this is actually a misleading error message. The actual error is Errno::EACCES which can be caused by several things: a file permissions error, or by a network connection permissions issue such as a firewall.
I my case, it was my firewall, TinyWall, that was blocking ruby.exe from connecting to the internet and thus causing this error. By giving it access through the firewall, bundle install ran successfully.
Just putting this out there for anyone else that may encounter this frustrating issue one day.

Related

Unable to modify permissions of folders on Mac (Mojave)

I am new to Macs and I am trying to run some interesting stats on my iMessages using the code runner extension on VSCode. I've been following this post: https://towardsdatascience.com/heres-how-you-can-access-your-entire-imessage-history-on-your-mac-f8878276c6e9
However, when I run the line conn = sqlite3.connect('/Users/<username>/Library/Messages/chat.db')
I get the error sqlite3.OperationalError: unable to open database file
Based off what I can tell my issue is that VScode doesn't have the right permissions to access the ~/Library/Messages folder and possibly the chat.db as well. First, I ran ls -l on Library and the result is drwx---rwx for Messages. So I tried to use both chmod a+rwx Messages and sudo chmod a+rwx Messages to open permissions to everything but got the error chmod: Unable to change file mode on Messages: Operation not permitted both times.
Am I doing something wrong and/or is there a better way to do this? Or is it just not possible to change the permissions of this folder?
After some more creative searching I discovered that it was an Issue with Mojave's System Integrity Protection (SIP) and can be solved by giving the desired apps full disk access in Settings>Security&Privacy>Privacy>FullDiskAccess.
Solution found here

Apache Drill: Local udf directory must be writable for application user error

I'm trying to get Drill up and running on my machine. However, whenever I enter drill-embedded mode (bin/drill-embedded on Bash), I get this error:
Error: Failure in starting embedded Drillbit: java.lang.IllegalStateException: Local udf directory [/tmp/drill/udf/udf/local] must be writable for application user (state=,code=0)
If I try to run a query at this point, it'll give back:
No current connection
Any idea how to fix this? I've tried starting with a clean shell with no luck. Is it a permissions issue?
You have to give the directory /tmp/drill/udf/udf/local write access. Since it is a directory in /tmp, you might need root access to give permissions, or you will have to use sudo. To give permission, use this:
chmod 777 -R /tmp/drill/udf/udf/local
Also make sure the user is having at least read permission on the parent directories, otherwise you will get a permission denied error again.

openshift DIY, 503 error after deleting and adding again testrubyserver.ruby file

I am trying openshift DIY cartridge. I use a windows system to manage the server from command line. I managed to run a simple html5 website. I have deleted the testrubyserver.ruby file from the webpage folder for test purposed and then added it again to my webfolder. Now i have 503 error. No restart, no stop, no start helps. I am stuck in 503. Does anyone know what to do? How can I make the testrubyserver.ruby run again?
Solved my problem. I checked the log file in the folder: app-root / logs. There I found out that
nohup: failed to run command `/..//testrubyserver.rb': Permission denied
I change in filezilla the permissions for the file from rw to rwx to execute it. Restarted the server and then it worked.
I do not know if this is the right approach. At least it makes my app running again.

Joomla administrator login error

I have a Joomla 3.1 installation on a ubuntu server and it was working fine.
Today, I have downloaded a template and placed the zip file on templates folder, unziped by ubuntu terminal and that's all. Since then, when I try to login on Administrator side, it gives this error:
An error has occurred.
0 SQL=SHOW FULL COLUMNS FROM `<prefix>_users`
I have deleted the zip files considering it was the only change I've made, but nothing happens. I noticed that if I login incorrectly, it gives another error:
An error has occurred.
0 Cannot open file for writing log
Like it has some problem to write the log file, but hours ago it could. Anyway, knowing this, I changed all folders/files permissions to 777.
Thanks in advance.

BlogEngine.Net - "Unable to generate a temporary class" error

I just uploaded a new instance of blogengine.net to a subdomain on my host and I am getting the following error:
Unable to generate a temporary class
(result=1). error CS2001: Source file
'C:\WINDOWS\TEMP\jn5ced1y.0.cs' could
not be found error CS2008: No inputs
specified
I do have VPS plan on my host, do I need to ask for specific permissions?
On previous installs (older versions) of BE I never had this problem - did I do something wrong?
Thank you.
Sounds like a permissions issue on the TEMP directory. I've had the same issue locally on my development machine and took the naughty EVERYONE/ALL route to resolve.

Resources