Jolokia - where is jolokia-access.xml? - jolokia

I recently started to use Jolokia (on Weblogic server on a Windows VM) and it was fine (i.e. I could access to http://:/jolokia/version). However, after setting up credentials for an user, I find that I couldn't access to http://:/jolokia/version and it returned 403 Forbidden error. After reading through this page (https://jolokia.org/reference/html/security.html), the issue seems related to jolokia-access.xml. I tried to find it on server (Windows VM) but failed. I also tried to search for it online but couldn't find it either.
Could you please let me know where the file is? If I need to create the file, where (i.e. path) should I put it?
Thanks!

this file is there in this path:
c:<ACTIVEMQ_DIR>\webapps\api\WEB-INF\classes\jolokia-access.xml

Try to find in the conf directory in the activemq installation directory:
c:\<ACTIVEMQ_DIR>\conf\jolokia-access.xml

Related

Unable to login to the RabbitMQ using guest

I have the following issue. I deleted the guest user and now basically I cant login to rabbitmq using guest-guest.
I have tried the following things:
1) I did uninstall the service and install it again. It didn't work. It worked for some other colleagues but it didn't work for me. I have tried to uninstall/install nearly 10 times. I can see the service disappearing and readded. Still no success
2) Config file. The config file resides in the following location :
C:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.5.1\etc\rabbitmq.
I removed the comments from the following setting :
It was like that
%% {loopback_users, []},
and now it is
{loopback_users, []},
still no success. I restart the service every time i modify the config file but still no success. It was working before I delete the guest user. Does anyone know what else could I do or what am i doing wrong??
Thanks!!
Try again but with the config file found in:
C:\Users\<<Username>>\AppData\Roaming\RabbitMQ
For environment changes to take effect on Windows, the service must be re-installed. It is not sufficient to restart the service.
You can re-install from Start Menu > RabbitMQ Server > RabbitMQ Service - re(install)

XAMPP - Apache could not start - Attempting to start Apache service

While trying to start Apache using XAMPP, I was receiving - "Attempting to start Apache service..." message in XAMPP UI. No further details were available.
Where can I see the logs (I was running XAMPP as Admin) ?
IF PORT 80 IS NOT THE ISSUE!
Check to see if the port 80 is in use first as this can be an issue.
You can do this by typing "netstat -an" into cmd. The look for 0.0.0.0:80 under Local Address, if you find this is in use then follow the solution from #Karthik. However, I had a similar issue but my port 80 was not in use.
My XAMPP had wrong paths locations, steps to fix this:
1.Find out the Apache version you are using, you can find this by looking in Services (Control panel, Admin Tools, Services) and finding Apache in my case it was listed as Apache2.4
2.Close XAMPP.
3.Run cmd as admin.
4.execute 'sc delete "Apache2.4"' (put your version in place of mine and without the surrounding ' ', but with the " " around Apache).
5.execute 'sc delete "mySQL"', again remove the '' when you type it.
6.reopen XAMPP and try starting Apache
If you are having trouble with FileZill, Mercury, or Tomcat you could try it here too, but I have not tested that myself.
Hope this helps!
I realized it was a port issue since I was running IIS and other web servers in my machine. But I was more interested to see a detailed error message with the port number in the UI.
Seems like it was not logged in the UI or log file (at least in my case), but in the Event viewer (Control panel -> View Event Logs). Under the Even viewer -> Windows Logs -> Application
I could see a permission error something like the below one:
An attempt was made to access a socket in a way forbidden by its access permissions. : AH00072: make_sock: could not bind to address 0.0.0.0:443
To fix this permission issue for SSL port, Please change the below line in httpd-ssl.conf (C:\xampp\apache\conf\extra)
# When we also provide SSL we have to listen to the
standard HTTP port (see above) and to the HTTPS port
Listen xxx
Replace XXX with any valid port number that is open in your machine
If you are having issues with Port 80, then change the httpd.conf file (C:\xampp\apache\conf)
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 127.0.0.1:8000
I have also summarized other solutions that I came across:
Most often Skype blocks the Apache port. So terminate it and try again.
Find the process id (PID) that is using the Blocked port ( netstat -ano) and kill the corresponding process in Windows Task Manager.
For those who have accidentally (or not) changed one of the .conf files and apache does not run even after trying all the above solutions.
One easy way to track where the issue is located, is to run Apache via command prompt:
(On windows) : open command prompt as admin then navigate inside the bin folder of Apache , next run
httpd in order to run apache
C:\xampp\apache\bin\httpd
For my case it was :
someone had added a virtual host in the specific file that caused the problem . I commented the lines and Apache ran fine.
start xampp (as administrator),
(1) right click C:\xampp\xampp-control.exe, and run as administrator.
(2) unistall service module and then install service module.
(3) now try start the apache and mysql.
Check your DocumentRoot path (in httpd.conf); a typo there can cause this problem.
Had the same issue while updating to PHP7.2
Problem:
First I closed skype and then checked whether port 80 is not an issue. How you can check that? See #AlexT comment above.
In my case, port 80 wasn't an issue. So now I had to figure out what was wrong. So I checked Error Logs Control Panel > Even viewer > Windows Logs > Application and found following error against Apache2.4
httpd.exe: Syntax error on line 520 of C:/xampp/apache/conf/httpd.conf: Syntax error on line 18 of C:/xampp/apache/conf/extra/httpd-xampp.conf: Cannot load C:/xampp/php/php7ts.dll into server: The Apache service named is not a valid Win32 application.
Which means I had installed wrong PHP version. Actually I downloaded win64 version while the required version was Win32 for me.
So I downloaded correct version from: Download PHP 7.2.0 extracted it in C:/xampp/php folder, restarted the apache and it worked :)
I had the same issue, executing "setup_xampp.bat" in xampp folder solved my issue.
I had the same problem but it was because I had a previous version of xampp already installed and I tried to install a newer version. I had installed the newer version in another file directory (I had named the file directory xampp2). I solved the problem by uninstalling the newer version, renaming the old one (I renamed it xamppold) and I installed xampp again.
I guess if you haven't installed xampp in another file directory , it should be enough to reinstall xampp. If you are worried about your files , you always can make a backup before reinstalling xampp.
I solved the problem after watching the xampp activity log (the list of the bottom) and realizing xampp was trying to open the custom file path but I had another route path. If the first option didn't work, at least you can scroll up in the activity log and see what's error you get while starting as admin and trying to re install the Apache module or trying to start the module.
You may wander why I didn't just simply uninstall the whole thing from the beginning , and the answer would be because I had to tweak a couple of things in xampp for some different projects (from changing the ports , to add .dll to run mongo.db in Apache), and I was just too lazy to re-do everything again :b
I hope my answer can be helpful for anyone since this is my first time writing in stackoverflow :)
Cheers
In my case, with the same problem and Xampp window, I had copied \apache\conf\extra\httpd-vhosts.conf entries from an old Xampp version to a newly installed one so I could continue to open local projects in browsers. One of the vhosts paths was wrong. After deleting that entry Apache started without problem.
The reference by #Karthik to "in the Event viewer (Control panel -> View Event Logs" saved me time. It's all too easy to presume Xampp logs will point to the problem. It doesn't.
Also check if your xampp is installed in the main directory like C or D or E and not in or within a folder of that directory? i.e. ( "D:/Xampp" or is it "D:/something/Xampp") if its not in the main path of the directory, it will show this error.
copy your xampp directory from "D:\Something\Xampp" to "D:"
So it becomes like this "D:\Xampp"
and the issue will be resolved.
Starting Xampp as a console application (simply by doubleclicking xampp_start.exe in the Xampp root folder) was the only thing that worked for me on Windows 10 (no Skype, no Word Wide Web Publishing Service). WampServer and UwAmp also didn't work.
I had a hard-coded IP in httpd.conf and my local IP had changed which was causing my issue, changed IP over and all worked again
My scenario was different after I tested all the possible options. If you have changed the ports and still get the same problem, well here's something you can try out. This was done in Windows 7.
Step 1: Confirm the cause of the error by going to Control Panel -> System and Security -> Administrative Tools -> Event Viewer -> Windows Logs -> Application -> Error. Mine said "The Apache service named reported the following error:
httpd.exe: Syntax error on line 424 of C:/xampp/apache/conf/httpd.conf: Cannot load c:\xampp\php\php5apache.dll into server: The specified module could not be found." So I needed to change \php5apache.dll to the version of my php and apache version installed which was php7apache2_4.dll
Step 2: To get the correct name for your .dll php and apache file, got to C:\xampp\php. You will see something like php7apache2_4.dll with other files in the folder.
Step 3: Go to C:/xampp/apache/conf/httpd.conf and edit the configuration file and change "c:\xampp\php\php5apache.dll" to "c:\xampp\php\php7apache2_4.dll" in my case. Make sure you open the file as administrator save changes made.
Step 4: Run the xampp server and everything should work fine. Do not forget to shut down the xampp server before doing the changes to the apache configuration file.
Hope this helps. Cheers! :)
Try to install x86 version of XAMPP. The default XAMPP version on their website is x64 (maybe because I'm using x64 Windows 7).
download link here
I had this issue when I installed under Program Files, which they do not recommend due to write issues. This might only be a problem if you are not logged in as an admin and use a password to install. I just uninstalled and installed in a directory that did not need admin privileges.
Make sure Apache didn't get Disabled in Services (Control panel, Admin Tools, Services). If it's Disabled then Set it to Manual and it should run. That was my case, I found Apache Disabled.
Solution for my particular scenario (It had been working a couple days before getting borked):
Port 80 was not the problem, but something I had done while messing around with Services and Startup.
Type msconfig on Windows' Start menu
Click System Configuration
Screenshot for System Configuration
In the Services tab, search for Apache24 (Click "Hide all Microsoft services" in the checkbox at the bottom of the window to make it easier to find)
If its checkbox isn't checked, check it
If it was already checked, then this guide isn't going to help. However if it is:
Click OK, your PC will have to restart
Try once again! In my case Apache was already running once I opened Xampp
I had the same issue.Just click on services button.Then find apache and right cick > properties > set startup type as Automatic/ Manual. Now close apache and try again.It will work!
For me it wasn't a port or service issue; I had to re-run the XAMPP setup script. Although this didn't directly fix the issue for me, the script was much more verbose than the XAMPP log, pointing me in the right direction to actually solve the problem.
From the XAMPP GUI, click on Shell, type set, press Tab to autocomplete to the setup_xampp.bat file, and then press Enter to run it.
In my case I got the following output:
[ERROR]: Test php.exe failed !!!
[ERROR]: Perhaps the Microsoft C++ 2008 runtime package is not installed.
[ERROR]: Please try to install the MS VC++ 2008 Redistributable Package from the Mircrosoft page first
[ERROR]: http://www.microsoft.com/en-us/download/details.aspx?id=5582
This particular error is misleading. Although it specifies the Visual C++ 2008 Redistributable Package, PHP 7.4.x requires the Visual C++ 2019 Redistributable Package.
After installing that and following the prompt to restart, sure enough I'm now able to start Apache as normal.
make sure no space in front of the port number if you ever edited it.
From Xampp control panel, click on config (next to Apache), then choose Apache(httpd.config), search for listen 80 and change the port to another port.
If nothing works with you, I would suggest you download MAMP and use it instead.
It does the same thing, if not better.
Comment this lines from httpd.conf:
# Virtual hosts
#Include etc/extra/httpd-vhosts.conf
In the case you're using them it may solve.
when i run xampp control panel normal:
I had been run
I can’t start apache
So, I will run it with administrator:
I can run apache

Why won't Apache Server start in MAMP?

I'm trying to view php files locally on my mac.
I'm running Yosemite.
I have MAMP installed on my computer. When I press start the MySQL server starts but Apache doesn't. An error message appears saying 'Error. Apache couldn't be started. Please check your MAMP installation'
I've gone through the internet typing stuff into terminal and changing 'envvars' to '_envvars' but nothing works.
I reinstalled OSX and that worked but when I shut down the computer the problem occurs again.
Can anyone help?
Thanks
Check if you changed the Document Root Location or Renamed it. At least this was my mistake.
MAMP > Preferences > Web Server > Document Root
I didn't get it working with port 8000 or the default 8888, but did get it working with port 80 per the suggestion here:
http://forums.macrumors.com/showthread.php?t=1744944
That didn't work after all, but it didn't error out. However I manually ran the following at the command line (because log file was empty):
sudo /Applications/MAMP/Library/bin/apachectl start
Only to find that after upgrading I was missing the mod_example.so
httpd: Syntax error on line 83 of /Applications/MAMP/conf/apache/httpd.conf: Cannot load /Applications/MAMP/Library/modules/mod_example.so into server: dlopen(/Applications/MAMP/Library/modules/mod_example.so, 10): image not found
Copied it from my old install and I was good to go.
If you try to start the server from the terminal, likely that will tell you what is wrong e.g.
sudo /Applications/MAMP/bin/startApache.sh
Password:
(48) Address already in use: make_sock: could not bind to address [::]:8888
(48) Address already in use: make_sock: could not bind to address 0.0.0.0:8888
no listening sockets available, shutting down
Unable to open logs
What you can do in this case, I was inadvertently running a Blockstack browser out of 8888, so changing MAMP to 8887 allowed it to start. [Your mistake might be different.]
Had the same problem, nothing in the logs. After trying the_dillio's suggestion:
sudo /Applications/MAMP/Library/bin/apachectl start
I got an error that pointed back to my vhosts file. It turns out I had an extra /VirtualHost tag. Removed it and it started working again.
i've solved this issue using this command in the terminal :
sudo apachectl stop
I think I've found the solution.
It was the wrong port. I altered the .conf file in the Apache folder. I changed all instances of port 8888 to 8000. When I run MAMP now it all seems to work fine.
Thanks for your help
Also be aware that if you by any chance deleted the folder that was set as Document Root the last time you were using MAMP, you will get this error. Simply open MAMP again, change Document Root to a location that does exist and start the servers.
I received the same error but interestingly it was caused simply because I renamed the root folder and didn't realize it. Sounds like you have a different issue but for anyone else who gets this error message, make sure you haven't renamed the root!
Absolutely bizarre behavior for MAMP PRO (paid license too btw...)
In my case I had to change the location of the log file in order to get it to work...
Click on Mysql icon then the little folder to the right of the path and try changing it to something else.
For MAMP :
You can open the terminal and write:
ps aux | grep mysql
lsof -i
killall -9 mysqld
I hope is good for you!
Bye
I had this experience when upgrading to V4. It tried to used the files from my previous installation and it just never worked. The workaround was to RENAME the original MAMP installation to something different than "MAMP", install brand new version and then copy files you may need like VHOST configs and DATABASES. After all this it worked just fine.
My Apache server problem arose after I enabled SSL. So if this is your case, check your https-ssl.conf file (Applications -> Mamp -> conf -> apache -> extra). The Document Root under the Virtual Host settings had a different file path for htdocs than where it was actually located (easily overlooked). I changed this to "/Applications/MAMP/htdocs" and problem solved. Perhaps also check Document Root in your https.conf file (Applications -> Mamp -> conf -> apache) to see if it has the correct file path to htdocs too.
These are the steps I used to solve this issue.
Checking vcredist that are required and installing them. to check which are the missing vcredist I used a tool called "check_vcredist" from wamp.
I also installed latest Microsoft Visual C++ Redistributable x64.
Doing this steps solved my issue of Apache server not running

Run Webapp stored on network drive in Visualstudio

Im going crazy! I hope you can help me with an advice.
Inside Virtualbox I do run a Windows Server 2008 R2. On this machine im trying to debug a webapplication inside Visualstudio 2010. the webbapplication is stored on a network drive.
Well the network drive is truly a partition of my hdd. because of the shared folder the virtual machine recognize it like an network drive but in my opinion i doesnt matter to the actual problem.
When i try to start the applition a get an error like this:
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a
configuration file required to service this request. Please review the
specific error details below and modify your configuration file
appropriately.
Parser Error Message: An error occurred loading a configuration file:
Failed to start monitoring changes to 'E:\Testing\In Work\5.1
SP1\SitefinityWebApp'.
Source Error:
[No relevant source lines]
Source File: E:\Testing\In Work\5.1
SP1\SitefinityWebApp\web.config Line: 0
Version Information: Microsoft .NET Framework Version:4.0.30319;
ASP.NET Version:4.0.30319.18034
I allready tried get fulltrust to the application via caspol using the following:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\CasPol.exe -m -ag 1 -url "file:////\\VBOXSVR\d_drive\Testing\In Work\5.1 SP1\SitefinityWebApp*" FullTrust -exclusive on
or this
C:\Windows\Microsoft.NET\Framework\v4.0.30319\CasPol.exe -machine -addgroup All_Code -url "E:\Testing\In Work\*" FullTrust
but nothing helped!
Has anybody an solution?
p.s.
if i run the same project on the virtual hdd it works fine!
It seems that network drives can't be monitored by Windows for file changes like local drives can so in fact it matters where you put your source code so your WebApp can automagically reload it on changes - here a possible but maybe outdated solution is given.

rabbitmqctl.bat on Windows XP: unable to connect to node rabbit#MYPCNAME: nodedown

I have just installed RabbitMQ on my WindowsXP PC. I have fulfilled the Erlang OPC15 prereq as well.
My rabitmq seems to be working. I did a simple test using pika in python and it seems to work. The service is urnning.
The problem is that I cannot do anything with rabbitmqctl.bat. I always get the response:
Status of node rabbit#MYPCNAME ...
Error: unable to connect to node rabbit#MYPCNAME: nodedown
diagnostics:
- nodes and their ports on MYPCNAME: [{rabbit,3097},{rabbitmqctl17251,1132}]
- current node: rabbitmqctl17251#mypcname
- current node home dir: C:\Documents and Settings\Myuser
- current node cookie hash: NOTSUREIFTHISISSENSITIVESOREMOVED==
In my rabbitmq log file I get:
=ERROR REPORT==== 12-Feb-2012::17:01:22 ===
** Connection attempt from disallowed node rabbitmqctl17251#mypcname **
From various forums I deduce this has something to do with cookies. What cookies are we talking about? What do I need to do to be able to manage my RabbitMQ instance using rabbitmqctl.bat? Please word your answer in a way that a non-erlang non-functional programmer would understand.
Had the same problem, this instruction straight out of the manual installation guide solved my problem:
Synchronise Erlang Cookies (when running a manually installed Windows Service)
Erlang Security Cookies used by the service account and the user
running rabbitmqctl.bat must be synchronised for rabbitmqctl.bat to
function.
To ensure Erlang cookie files contain the same string, copy the .erlang.cookie file from the Windows directory (normally C:\WINDOWS\.erlang.cookie) to replace the user .erlang.cookie. The user cookie will be in the user's home directory (%HOMEDRIVE%%HOMEPATH%), e.g. C:\Documents and Settings\%USERNAME%\.erlang.cookie or C:\Users\%USERNAME%\.erlang.cookie (Windows Vista and later).
Shortcut command for #Lining answer:
copy C:\Windows\.erlang.cookie %HOMEDRIVE%%HOMEPATH%\.erlang.cookie
Try to create a file called .erlang.cookie in your $HOME directory and put a simple passphrase in there.
Then restart rabbitmq and it might work. If it doesn't then rabbitmq is doing something to make sure you cannot put a system wide cookie in place.
It worked for me after replacing ".erlang.cookie" file under c:\Windows in C:\Documents and Settings\username folder, because cookie should be same as per my understanding.

Resources