general/other seeking Linuxulator tips and tricks

I have been wanting to get Charles proxy working on FreeBSD since last year. I finally got around to tampering with it and it actually works. I am using Linuxulator and OpenJDK with the proxy files stored in /opt/charles. I made a launcher and tested it using Firefox. Screen capture attached.

As a reminder to the forum, i have been a Windows only user since 1999. I have very little experience with Linux and only entry-level experience with FreeBSD. I have alot to learn. I know what Linuxulator is and how to utilize it but i am wondering about security. Are we supposed to do anything security-wise that i have yet to learn? other questions come to mind:

Are there any caveats to using Linuxulator that i should be aware of?
Are there other benefits to using Linuxulator besides running Linux binaries?
Is there anything that i should know about Linuxulator that isn't mainstream knowledge?
what is the overall opinion about Linuxulator being used in FreeBSD (hate it, love it)?
 

Attachments

  • FreeBSD-Charles.png
    FreeBSD-Charles.png
    135.9 KB · Views: 35
Hello cracauer@

I did not think about /proc, so this is a very good tip, indeed! Thank you, Sir. I've saved a few documents discussing the matter and i will read them in the future. I like this feature of FreeBSD. I am preparing to replace my Windows 11 laptop with FreeBSD 15, thus i am playing with various tools and utilities to make myself feel at home on FreeBSD. I like Charles Proxy better than Fiddler, so making it work in FreeBSD is a major plus for me. I am happy with Linuxulator functionality. Very nice feature :)
 
If it's a Java application, why run it on a Linux OpenJDK when there's a 'native' OpenJDK available? Or am I misunderstanding something here?
Well, several libraries include native shared libraries for each supported os/arch (usually linux-x86, linux-x86_64, linux-aarch64, win-x86, macos-x86, etc). Most libraries use the reported OS/arch to select the appropriate native library to load, which for FreeBSD will fail because the native OpenJDK is not supported. Sometimes you can work around this by forcing a runtime/arch environment variable. Other times it will fallback to a pure java implementation (slower).
A good example of this pain is SWT (native widgets for java, used by eclipse and eclipse rcp apps like dbeaver), SWT has no builds for freebsd so that is a pain because it requires freebsd packagers to also take care of that component. Another example are network/crypto libraries (like netty, bouncycastle) which also use shared libraries.

Because I work with these constrains a lot (plus docker requirements), I've exploited/hacked /linux/compat and linuxlator a lot. On the plus side I can confirm that it's more than up to the task and integration is pretty good overall.
 
Well, several libraries include native shared libraries for each supported os/arch (usually linux-x86, linux-x86_64, linux-aarch64, win-x86, macos-x86, etc). Most libraries use the reported OS/arch to select the appropriate native library to load, which for FreeBSD will fail because the native OpenJDK is not supported. Sometimes you can work around this by forcing a runtime/arch environment variable. Other times it will fallback to a pure java implementation (slower).
A good example of this pain is SWT (native widgets for java, used by eclipse and eclipse rcp apps like dbeaver), SWT has no builds for freebsd so that is a pain because it requires freebsd packagers to also take care of that component. Another example are network/crypto libraries (like netty, bouncycastle) which also use shared libraries.

Because I work with these constrains a lot (plus docker requirements), I've exploited/hacked /linux/compat and linuxlator a lot. On the plus side I can confirm that it's more than up to the task and integration is pretty good overall.

Java. Write once, run everywhere. Sure :)
 
If it's a Java application, why run it on a Linux OpenJDK when there's a 'native' OpenJDK available? Or am I misunderstanding something here?
misunderstanding. I enable Linuxulator and install OpenJDK (via pkg). I also had to install the linux-rl9-xorg-libs package.

fahrenheit has eloquently answered your question regarding Linux OpenJDK, so i have nothing to add.

 
Back
Top