access to xrdp localhost webserver from my navigator - remote-access

its been a while since i ve been stucked with this.
i created a redmine application on a xRDP and everything is alright, i can lunch it with puma or rails, without issues. but when i go to my chrome and try to Access to my application a write : 172.x.x.x:3000 and i have
Ce site est inaccessible 172.x.x.x a mis trop de temps à répondre.
Voici quelques conseils :
Vérifier la connexion
Vérifier le proxy et le pare-feu
Exécutez les diagnostics réseau de Windows
ERR_CONNECTION_TIMED_OUT"
the log when i start the server with : puma -e production -p 3000
Puma starting in single mode...
* Puma version: 5.6.2 (ruby 2.7.0-p0) ("Birdie's Version")
* Min threads: 0
* Max threads: 5
* Environment: production
* PID: 78413
/var/lib/gems/2.7.0/gems/activerecord-5.2.6/lib/active_record/associations.rb:1855: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call
/var/lib/gems/2.7.0/gems/activerecord-5.2.6/lib/active_record/associations.rb:1368: warning: The called method `has_many' is defined here
/var/lib/gems/2.7.0/gems/actionpack-5.2.6/lib/action_dispatch/middleware/stack.rb:37: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call
/var/lib/gems/2.7.0/gems/actionpack-5.2.6/lib/action_dispatch/middleware/static.rb:111: warning: The called method `initialize' is defined here
* Listening on http://0.0.0.0:3000
Use Ctrl-C to stop
to resume i want to access to my xRPD redmine from my navigator so everyone can use it without using the remote controle.
if you got any ideas i will be gratefull, Thank you guys for your help

i found the issue, the probleme was the port 3000 (IN/OUT) that wasnt open on the Xrdp, i hope that this will help anyone that have the same issue.
Best regards

Related

django.db.utils.DatabaseError: Error while trying to retrieve text for error ORA-01804

Q1. What versions are we using?
Ans.
Python 3.6.12
OS : CentOS 7 64-bit
DB : Oracle 18c
Django 2.2
cx_Oracle : 8.1.0
Q2. Describe the problem
Ans. While running server with "python3 manage.py runserver"
application is able to contact Oracle DB and show the Django Administration page and login also works.
But when we access the application using the Apache (HTTPD) based URL over secure SSL port, we do see the Django page and the admin page as well but Login to Admin page with Internal server error.
In the logs, we see
"django.db.utils.DatabaseError: Error while trying to retrieve text for error ORA-01804"
cx_oracle is otherwise able to connect to the database properly, another application is also using the same database behind the same httpd proxy and works fine
Q3. Show the directory listing where your Oracle Client libraries are installed (e.g. the Instant Client directory). Is it 64-bit or 32-bit?
Ans. 64-bit
Q4. Show what the PATH environment variable (on Windows) or LD_LIBRARY_PATH (on Linux) is set to?
LD_LIBRARY_PATH=/srv/vol/db/oracle/product/18.0.0/dbhome_1/lib:/lib:/usr/lib
PATH=$ORACLE_HOME/bin:/srv/vol/db/oracle/product/18.0.0/dbhome_1/lib:$PATH
Q5. Show any Oracle environment variables set (e.g. ORACLE_HOME, ORACLE_BASE).
ORACLE_HOME=/srv/vol/db/oracle/product/18.0.0/dbhome_1
TNS_ADMIN=$ORACLE_HOME/network/admin
NLS_LANG=AMERICAN_AMERICA.AL32UTF8
ORACLE_BASE=/srv/vol/db/oracle
CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib:$ORACLE_HOME/lib
Any suggestions/help is highly appreciated.
Thank you
I found the problem
So I just removed all the variable declarations from /etc/sysconfig/httpd and checked, the application was still able to access the lib files, so these were now redundant.
Then undid all variable declarations done earlier in .localsh and .localrc files for the os users. To start from scratch, and go step by step to see where it breaks.
So now, cx_Oracle was looking for the lib files in wrong directory
$ORACLE_HOME/client_1/lib
instead of
$ORACLE_HOME/lib
DPI-1047: Cannot locate a 64-bit Oracle Client library: "$ORACLE_HOME/client_1/lib/libclntsh.so: cannot open shared object file: No such file or directory". See https://cx-oracle.readthedocs.io/en/latest/user_guide/installation.html for help
I did not have any subfolder named "client_1" inside dbhome_1
so I just created a symlink client_1 that points to dbhome_1 (still unsure on this, but at least it works :) )
So, now, this error was gone but now again ORA-01804 was coming. 😑
I had read somewhere that this error can be fixed by adding "libociei.so" but I did not have one on my instance, so I generated it using these commands:-
mkdir -p $ORACLE_HOME/rdbms/install/instantclient/light
cd $ORACLE_HOME/rdbms/lib
make -f ins_rdbms.mk igenliboci
Then I just moved this libociei.so file from
$ORACLE_HOME/instantclient to $ORACLE_HOME/lib
Now there was a new error (so.. progress 😉 ):
ORA-12546 - TNS Permission Denied.
This was easy to solve 😀
I used this command to address this :-
setsebool -P httpd_can_network_connect on
And...... That was all! It worked.

Azure Application Insights agent for Java causing Could not find or load main class %JAVA_OPTS on JBoss 18

I am implementing Azure Application Insights in Java application. Azure Docs
I have added below configure in standalone.conf JBOSS/WildFly configuration
However when I start the server I am getting below error
[root#server-1 bin]# ./standalone.sh
=========================================================================
JBoss Bootstrap Environment
JBOSS_HOME: /opt/wildfly
JAVA: /usr/lib/jvm/jdk1.8.0_261/bin/java
JAVA_OPTS: -server %JAVA_OPTS% -javaagent:/tmp/azurejar/applicationinsights-agent-2.6.1.jar
=========================================================================
Error: Could not find or load main class %JAVA_OPTS
Could you please help me to resolve this issue ? Any help is much appreciated.
That's Windows syntax. In a Unix-based environment like Linux you use the $ to access environment variables. Change the %JAVA_OPTS% part of the line to $JAVA_OPTS, i.e.:
JAVA_OPTS="$JAVA_OPTS -javaagent:/tmp/lib/applicationinsights-agent-2.6.1.jar"

Xampp mysql error #2002

anyone can help me, how to fix this
when i open localhost/phpmyadmin/
it says
Error
MySQL said: Documentation
#2002 - No connection could be made because the target machine actively refused it.
The server is not responding (or the local server's socket is not correctly configured).
Connection for controluser as defined in your configuration failed.
when i run mysql_start.bat, it says
Diese Eingabeforderung nicht waehrend des Running beenden
Please dont close Window while MySQL is running
MySQL is trying to start
Please wait ...
MySQL is starting with mysql\bin\my.ini (console)
MySQL konnte nicht gestartet werden
MySQL could not be started
Press any key to continue . . .
i tried to fix it with solution that provided in google before
but it still doesn't work
If you view the file mysql_start.bat it has a generic error that is printed irrespective of the MySQL error.
Try to open a command prompt and type the below command which is available in the mysql_start.bat file.
mysql\bin\mysqld --defaults-file=mysql\my.ini --standalone --console
Running the exact command in the prompt will show you the MySQL error. In my case it was the my.ini was missing and I had to rename one of the sample files and put it to the location.

Error on neo4j server start on arch linux

I have an arch linux setup and installed neo4j through the arch user repository (yaourt -S neo4j), and I'm able to run the web console fine (sudo neo4j console with seemingly normal output and full functionality), however when trying to start the server (sudo neo4j start), I encounter the following error message:
/usr/share/neo4j/bin/utils: line 345: [: -lt: unary operator expected
Using additional JVM arguments: -server -XX:+DisableExplicitGC -Dorg.neo4j.server.properties=/etc/neo4j/neo4j-server.properties -Djava.util.logging.config.file=/etc/neo4j/logging.properties -Dlog4j.configuration=file:/etc/neo4j/log4j.properties -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled
Starting Neo4j Server...cat: /run/neo4j/neo4j-service.pid: No such file or directory
process []... waiting for server to be ready. Failed to start within 120 seconds.
Neo4j Server may have failed to start, please check the logs.
rm: cannot remove ‘/run/neo4j/neo4j-service.pid’: No such file or directory
There's no delay before the error message is printed, so it seems to be something other than the timeout. I'm quite new to neo4j (I worked through a fair bit of the user manual using the web console, but no development or server config experience), so I'm not really sure what else might be relevant. I tried looking through the utils script and the error appears to be where it attempts to su neo4j, but it also seems to proceed to attempt to start the server. I also tried changing the port it's starting on as in this question, but no change. The only log I can find just has this over and over (with appropriate timestamps):
Oct 15, 2014 1:33:49 AM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.9 09/02/2011 11:17 AM'
Any help at all would be appreciated!
EDIT:
The line 345 that it's failing on is the end of this snippet:
if [ $UID == 0 ] ; then
OPEN_FILES=`su $NEO4J_USER -c "ulimit -n"`
else
OPEN_FILES=`ulimit -n`
fi
if [ $OPEN_FILES -lt 40000 ]; then
From doing some echo debugging, it seems that su $NEO4J_USER is failing, probably because $NEO4J_USER is set to neo4j, a user that does not exist on my system. I tried setting that to root in one of the config files, but evidently that's not working properly. Arch is a continual learning experience for me, but I've not had to add a new user before to get software working.
The interesting line here is:
/usr/share/neo4j/bin/utils: line 345: [: -lt: unary operator expected
I assume that is caused by a wrong default shell for the neo4j user. What default is currently set for the neo4j system user? Try to switch that to bash. The startup scripts should work nicely with bash.

Problem with node.js and Redis-server?

I intended to implement a chat feature in my rails application. After a brief backup work I found JUGGERNAUT is the best option. By going to through http://juggernaut.rubyforge.org/
I have successfully implemented the juggernaut in my application.
Presently I'm all set to implement chat feature and after a vigorous surfing over web I couldn't get good tutorial to implement it but I found the some part of implementation at http://www.golygon.com/2010/12/private-chat-room-in-ruby-on-rails-3-0/. I decided to follow it but initially to implement the tutorial we need to have redis server and node.js in our system. I installed both in my environment.
But I'm facing the following problem as follows:
If I try
redis-server, I'm getting the following error
[11440] 08 Aug 10:08:16 # Warning: no config file specified, using the default config. In order to specify a config file use 'redis-server /path/to/redis.conf'
[11440] 08 Aug 10:08:16 # Opening port: bind: Address already in use
and as per the tutorial
if I try
sudo node server.js, I'm getting the following error
[sudo] password for re5:
node.js:63
throw e;
^
Error: ENOENT, No such file or directory '/home/re5/Documents/task17/server.js'
at Object.openSync (fs:153:18)
at Object.readFileSync (fs:94:15)
at Module._loadScriptSync (node.js:468:39)
at Module.loadSync (node.js:338:12)
at Object.runMain (node.js:522:24)
at Array.<anonymous> (node.js:756:12)
at EventEmitter._tickCallback (node.js:55:22)
at node.js:773:9
As I don't know much about the redis and node I'm unable to figure out what was the problem regarding to this errors.
I'm stuck and couldn't go further as I'm not sure whether this two are configured perfectly or not.
currently I'm using rails 3.0.7 and ruby 1.8.7
Can any one help me out.
Well your first error is quite simple to understand.
[11440] 08 Aug 10:08:16 # Opening port: bind: Address already in use
This means that there is aready a server bound to that port and using it as a server, this can happen if you have other applications/servers running or if you try to have mutiple instances of the server run at one time. To fix this you need to stop the process and then start it back up again. You can usually do this by closing all of your terminal windows or using your operating systems process manager to terminate the process, if those methods dont work for you try shutting your computer down and starting it back up. If you are still unable to start the Redis server after this then there are some more steps we can take.
The next error is due to node.js not being able to find a file that it needs. Reinstalling node.js should fix this problem for you.
Let me know if this fixes your problem or if you need more help.

Resources