I have a unit test that calls LSOF to get the number of open file handles. It runs fine on my machine, but on Travis builds (such as this one) I get this warning:
lsof: WARNING: can't stat() vmhgfs file system /Volumes/VMware Shared Folders
Output information may be incomplete.
assuming "dev=2d000003" from mount table
I did some searching, and it looks like the fix is to add this line to the advanced settings (or vmx file) for the machine's image:
isolation.tools.hgfs.disable=TRUE
Could someone please take a look at adding this?
Just ran into similar issue - https://superuser.com/questions/1082701/osx-on-vmplayer-running-on-windows-10-smb-shared-files-keep-getting-resource
Tried isolation.tools.hgfs.disable=TRUE. Sharing seems to be still enabled, but the problem persists.
Related
I do something like this
-javaagent:/usr/local/lib/perfino/perfino.jar=server=ybperfino,name=${HSTNAMESHORT}-${APPNAME},group=${YBENV}/${HSTNAMESHORT},logMBean=10,logFile=${LOG_DIR}/perfinologs/${HSTNAMESHORT}-${APPNAME}.log
basically I want the log files to be created in the log directory for the app not the home directory for the userid
but it seems like the log file isn't being created either with logfile argument or with out !
using java11 if that makes any difference.
Found the answer - I had a competing java agent that was loading before it.
After I changed the order both java agents worked.
So I work with RubyMine, and I configured my docker-compose integration like in this tutorial, but I have an error when I simply hit the 'run' button:
ERROR: Duplicate mount points: [/home/kyrela/railsproject:/railsproject:rw, /home/kyrela/railsproject:/railsproject:rw]
A simple docker-compose up from the terminal works.
I founded when trying to launch the same command as RubyMine, but removing some arguments, that it was caused by the docker-compose.override.[number].yml file generated automatically by RubyMine, based on my configuration. Without it, it works perfectly.
But my configuration is extremely basic :
I only set the IP adress and port, the same as the ones it currently use with a simple docker-compose up from the terminal, I set the remote SDK (the one from my container), and the docker-compose method to up. That's all, I leaved the rest blank or with the default value.
After some research on this error, it's apparently a bug that can be fixed with a simple docker-compose restart. It didn't worked for me.
Does someone know how to get rid of this error ?
If some informations are missing, just leave a comment and I will edit my message with the specified informations.
I know this question can be found a lot of time on this forum and the internet. But I can't seem to find the answer to my specific question.
I'm running a Drupal website, and since the update of MAMP from 5.5 to 5.6 I get the following error:
Fatal error: Allowed memory size of 1610612736 bytes exhausted (tried to allocate 4096 bytes) when running a composer require in the terminal.
I updated the php.ini tot 1024MB instead of 128MB of the current php version I'm running via MAMP. When I add a php file to my root with <?php phpinfo(); ?> I see that the memory is like I want so 1024MB. When I look at the location of the php ini file I see it is in the MAMP folder.
But I still get the error. When I run this php -r "echo ini_get('memory_limit').PHP_EOL;" in my terminal I see the 128MB again. When I try to find the php ini that is running using
php -i|grep 'php.ini' I get:
Configuration File (php.ini) Path => /etc
So it looks like the php.ini file is somewhere else. But I don't know where and can't change it. How can I solve this?
I also tried changing the composer memory using php -d memory_limit=-1 /usr/bin/composer but this didn't solve the problem either.
My question is, how can I solve this problem? How can I find the php.ini file that is used. Or how can I change the memory limit?
Update:
Running php -i | grep 'Configuration File' in the terminal ouputs:
Loaded Configuration File => (none)
And maybe good to know that I have the option Make this version available for command line enabled on the MAMP php section.
I tried many of the suggestions on this and a few other stack overflow questions but couldn't get it to work until I tried:
COMPOSER_MEMORY_LIMIT=-1 composer require 'yourpackagenamehere'
Just trying COMPOSER_MEMORY_LIMIT=-1 by itself before running the command didn't seem to work. Not sure why, but I had to run them on the same command line in a similar way as documented in the composer troubleshooting: https://getcomposer.org/doc/articles/troubleshooting.md#memory-limit-errors
I ended up adding a php.ini file to the /etc folder on my computer. This way the php memory_limit raise did work. And checking it in the terminal did show me the right value. But as Alister already said, this didn't fix the problem. The problem was not in the php.ini memory_limit.
I found out that using COMPOSER_MEMORY_LIMIT=-1 in the terminal at the beginning of my session put the memory limit to unlimited during that terminal session. This fixed the problem.
After that I added, alias composer="COMPOSER_MEMORY_LIMIT=-1 composer" to my bash file and know everything is working like I would expect.
Changing the amount of memory in php.ini won't help - that is the limit for what is being used by the webserver's version of PHP - and having too much available for the webserver can cause problems (at least when running in production).
Composer, when it is being run from the command line, will, by default set the limit to 1,610,612,736 bytes - 1.5 GB.
As you are apparently still on PHP 5.6, that's also a very considerable problem. PHP 7+ is a great deal more efficient with memory, as would be an up to date version of composer.
Finally, to actually solve the problem: Restrict your requirement to be more specific since that keeps memory usage lower.
I have a test which tries to start an embedded mysql.
It tries to write a socket file to Files.createTempFile(null, ".sock") which returns with the following error:
mysql start failed with error: [ERROR] The socket file path is too long (> 103): /private/var/tmp/_bazel_user/1c8ed8d84f6cb79483aa3cc4da758c86/bazel-sandbox/2478112867584790357/execroot/some_workspace/_tmp/dfebe48cda4dfdc8739653efedfa4933/394798020705754292.sock.
I worked around it by re-pointing java temp dir to /tmp using jvm_flags but this doesn't work when I try to use sandboxing since I guess the test isn't allowed to write there.
I've tried setting a symbolic link from the java code (like so Files.createSymbolicLink(Paths.get("/tmp/foo"),Paths.get(System.getProperty("java.io.tmpdir"))) but this doesn't seem to help.
I've also tried setting the output_base but that didn't help either.
Would really appreciate pointers and tips since I currently can't run my tests under sandbox and so can't parallelize them.
I think your approach of re-pointing Java to /tmp should work. The macOS sandbox always allows writing to a number of directories and /tmp and /private/tmp are included in this set. I tried to reproduce the failure with a genrule: genrule(name = "write_to_tmp", outs = ["out.txt"], cmd = "touch /tmp/something.sock && touch $#"), which works fine and creates the file /tmp/something.sock.
I think in general using /tmp should work fine, although it does seem to be a bit unusual on macOS. $TMPDIR is set to a user-specific folder with a randomized name underneath /var/folders by the OS and it seems to be generally encouraged to use that instead of /tmp. But if you know what you're doing, I don't see a real problem.
Note that we don't have tmpfs or similar mechanisms available on macOS, so we can't automatically guarantee that your usage of writable folders like /tmp by actions is hermetic, won't leak state between runs or that file names won't conflict. Make sure to generate file names in a secure way via mkstemp or similar.
In a bazel test, you can use the TEST_TMPDIR environment variable for a test-private writeable area.
See https://docs.bazel.build/versions/master/test-encyclopedia.html
I'm trying to make an Teamspeak image running on Alpine linux but am honest not sure why docker says
./ts3server: not found
This is the Github page with the Dockerfile code:
https://github.com/signofkoen/docker-teamspeak/blob/snapshot/Dockerfile
Container log:
/opt/teamspeak3-server_linux_amd64/ts3server_minimal_runscript.sh: line 8: ./ts3server: not found
Anyone know's what am doing wrong? I think a did something wrong with the extracting part but am not sure.
The ts3server binary in your image looks like it was built against glibc, but it is unable to find the appropriate runtime loader on the filesystem.
You can see this by running ldd /opt/teamspeak/ts3server, which reports:
Error loading shared library ld-linux-x86-64.so.2:
No such file or directory (needed by ts3server)
This is the direct cause of your error.
I see that you're starting with the skardoska/alpine-glibc image, which sounds like maybe it was designed to provide a standard glibc environment to Alpine linux, but the image does not appear to have been constructed in a way that is compatible with your binaries. Looking at the description at https://hub.docker.com/r/skardoska/alpine-glibc/, it appears this may be a known problem, because the description says, "Waiting for https://github.com/andyshinn/alpine-pkg-glibc/issues/1".
You may be better off just starting with a glibc based distribution like Fedora or Ubuntu.