Problem installing on Yosemite
Hi
after updating Xquartz and OS X Yosemite ver. 10.10.5 (14F1605) on my MacBoo Air (endi 2010), I have installed docker and openFoam following the instructions provided. Nor trying to run openFOAM I execute: > ./startOpenFOAM+ i get this message: non-network local connections being added to access control list of_v3.0_plus now typing: bash$ run I get this other message: bash: cd: /home/docker/OpenFOAM/docker-v3.0+/run: No such file or directory I have tried to create the above directory in vane. Any help please? |
mkdir $FOAM_RUN
|
Problem installing on Yosemite
Quote:
bash-4.1$ mkdir $FOAM_RUN mkdir: cannot create directory `/home/docker/OpenFOAM/docker-v3.0+/run': No such file or directory I also did this: bash-4.1$ mkdir /home/docker mkdir: cannot create directory `/home/docker': Permission denied and this: bash-4.1$ sudo mkdir /home/docker bash: sudo: command not found I also did the same using the csh: [Orfeo:~] dan% sudo mkdir /home/docker Password: mkdir: /home/docker: Operation not supported what else? thanks Daniele |
1 Attachment(s)
Here is the solution :
i) Open the docker terminal via clicking on "Docker Quick Start" short cut . ii) Delete old container: docker rm -f of_v3.0_plus iii)Open installOpenFOAM_MAC scripts (attached here. unzip it before using ) in line 25, replace strings NAME with your user name as appears in mac i.e /Users/Name to /Users/alex assuming alex is user name iv) run installOpenFOAM_MAC script as done earlier i.e docker-machine ssh default $HOME/installOpenFOAM_MAC $HOME v) Now run startOpenFOAM.sh script (http://openfoam.com/download/install-binary.php) and you will be login as root. vi) run following command to login as ofuser su ofuser Always work as ofuser to work on OpenFOAM vii) Go inside the folder /home/ofuser/workingDir and follow following steps a) mkdir OpenFOAM/ofuser-v3.0+/run b) cd .. c)ln -s workingDir/OpenFOAM (creating soft link to OpenFOAM/ofuser-v3.0+) Note: Please note that all changes inside container will be lost once you delete the container by command "docker rm -f contName" except content in /home/ofuser/workingDir . So if you are making changes in /opt/OpenFOAM better be careful . |
Quote:
I did not do as the "pgh" suggested (but I think it may work as well),but I fixed it another way(I do not know why lol...) First, you need to remove your openfoam docker image totally. Then, download the "installOpenFOAM+" from http://www.openfoam.com/download/install-binary.php There are two script start with "docker run ..." Use the second one, which is "docker run -it -d --name ${containerName} --user=${user} -e USER=${user} -e QT_X11_NO_MITSHM=1 -e DISPLAY=${displayVar} --workdir="/home/${user}" --volume="${home}:/home/${user}" --volume="/etc/group:/etc/group:ro" --volume="/etc/passwd:/etc/passwd:ro" --volume="/etc/shadow:/etc/shadow:ro" --volume="/etc/sudoers.d:/etc/sudoers.d:ro" -v=/tmp/.X11-unix:/tmp/.X11-unix ${imageName} /bin/bash --rcfile /opt/OpenFOAM/OpenFOAM-v3.0+/etc/bashrc" And use "#" to comments the first one. Other remain initial. Next,run "chmod +x installOpenFOAM+ " and " docker-machine ssh default $HOME/installOpenFOAM+ $HOME" That's it. |
Problem solved
Thanks to all replay the problem is solved.
Daniele |
I have same problem. None of the above worked. How did you solve it?
Thxs. |
Quote:
ii) Delete old container: docker rm -f of_v3.0_plus iii) Open installOpenFOAM_MAC script. in line 25, replace strings NAME with your user name as appears in mac i.e /Users/Name to /Users/alex assuming alex is user name in line 13 change of_v3.0_plus1 to of_v3.0_plus iv) run installOpenFOAM_MAC script as done earlier i.e docker-machine ssh default $HOME/installOpenFOAM_MAC $HOME v) Now run startOpenFOAM+ script and you will be login as root. vi) Go insider workingDir and follow following step a) mkdir OpenFOAM/ofuser-v3.0+/run (I had to make directories one by one, so first OpenFOAM then cd into it and make fuser-3.0+, cd uno it and make run b) cd .. (up to home directory /home/ofuser) c)ln -s workingDir/OpenFOAM (creating soft link to OpenFOAM/ofuser-v3.0+) vii) run this command su ofuser and you will login as ofuser (Always work as ofuser to work) Check carefully $HOME variable. When you try the first tutorials check also that variables $FOAM_RUN and $FOAM_TUTORIALS are coherent to your installation. You can find the scripts in the attach of PGH answer. Daniele |
It worked.
Thank you. |
Hi Daniele,
I tried your method, and it worked till the final step, ie I worked as ofuser. However, when I tried to run tutorials, I got "permission denied" when I tried to run cp -r $FOAM_TUTORIALS $FOAM_RUN What is the reason? |
Hi
Try to go inside $FOAM_RUN directory . i.e cd $FOAM_RUN and then run command cp -ar $FOAM_TUTORIALS. Even if it denies permission, then try to give all user permission to this folder i.e OpenFOAM/of-v3.0+ i.e to read and write |
Quote:
But there is a problem here. Every time I create a new folder I have to give it permission in order to write into this folder. Do you ever encounter this problem? |
No.. I created a folder in Users\pgh with name Projects and provides read+ write permission to it for every user. I put all my project in this directory and it is working fine .
|
Quote:
Editted to note: Hrmph. Seems my directory only exists inside the container. I am missing something regarding how stuff outside the container relates to stuff inside the container. I haven't figured out how to make the same directory visible on both sides and yet have correct permissions inside the container. |
1 Attachment(s)
Hi .. use this script and it should work fine .
i)delete old container docker rm -f of_v3.0_plus ii) run new script attached here (unzip the script first) Please place script in home folder and then run command from docker terminal as docker-machine ssh default $HOME/installOpenFOAM+ $HOME It will login as docker user and you can run openfoam and there will be no permission issue Also you can login as root now . password for root : 0fuser2015 Let me know if it works or you face any issue |
Quote:
bash-4.1$ cp -r $FOAM_TUTORIALS $FOAM_RUN I get: cp: cannot create directory `/home/docker/Users/OpenFOAM/JMM-v3.0+/run': No such file or directory This is a bit over my head and I'm confused as to what to try next. |
Hi,,
It looks to me you are using old script still . please use new script attached earlie(Note to delete old container before running script ) When you run script see the message it throw. In case you still have issue , send snaphot of those message i.e one coming while running) 1. Note that script name is different here , so make sure you use following command which use name of script which was attached earlier docker-machine ssh default $HOME/installOpenFOAM+_Mac_pgh $HOME 2. once you started container, i.e using ./start... ,, script . First type mkdir -p $FOAM_RUN (it basically create a folder with name OpenFOAM/docker-v3.0+ in your home area ile C\User\JMM .. |
Quote:
mkdir: cannot create directory `/home/docker/Users/OpenFOAM': Permission denied bash-4.1$ I don't know how to change permissions to create this. |
Which version of docker toolbox are you using ?
Go inside User folder and try to create a folder with name OpenFOAM with following command mkdir OpenFOAM If it works , then copy tutorial inside this folder cp -ar $FOAM_TUTORIALS . and try to run some tutorial . Even if you face permission issue , send your problem to docker@opencfd.co.uk. Some one from OpenCFD will look into this issue |
[Solved] Permissions Issues OS-X 10.11.5
1 Attachment(s)
Just successfully installed OF+ on OS-X 10.11.5 (El Capitan). This should work for Yosemite as well. Following the OpenFOAM official instructions, I kept running into the familiar permissions issues. Much thanks to pgh for the modified script/instructions found earlier in this thread. Here is a recap of the procedure to get OF running on Docker. This is assuming you already have Docker successfully installed.
0) Check you have the docker daemon running: Code:
docker info 1) In terminal, delete the old OF container (even if you haven't tried to create a container yet, it wont hurt): Code:
docker rm -f of_v3.0_plus Code:
docker ps -a 4) From Docker terminal, run the following commands to make the scripts executable: Code:
chmod +x installOpenFOAM_MAC_pgh Code:
chmod +x startOpenFOAM+_MAC Code:
docker-machine ssh default $HOME/installOpenFOAM_MAC_pgh $HOME 6) Start the Docker container with the following script: Code:
./startOpenFOAM+_MAC 7) You should now be able to create a run directory, hopefully without permissions issues Code:
mkdir -p $FOAM_RUN |
All times are GMT -4. The time now is 17:46. |