error to generate html to pdf using wkhtmltopdf after change parked server - apache

We have changed our parked server and before parked at new server script was working fine. but now script producing error
Server : ubuntu
PHP Framework : CI
Error is :
Could not run command '/usr/bin/wkhtmltopdf' --margin-top '4' --margin-right '4' --margin-bottom '4' --margin-left '4' --page-size 'A4' /tmp/tmp_WkHtmlToPdf_hGfaVM.html /tmp/tmp_WkHtmlToPdf_wAkzvA: wkhtmltopdf: cannot connect to X server

This is not really related to Codeigniter, but to the configuration of your server. (It might help to ask this question on Server Fault instead of Stackoverflow.)
1.) You should make sure that xserver is installed and running (it seems it's not.)
2.) As suggested by mic - Take a look at this question too.
Hope this helps. Good luck!

Related

Cannot install Glassfish update tool

Firstly, there are related posts:
GlassFish Server update center installation times out
Java EE 7 updatetool installation fails
I got my Java EE 7 SDK (Update 3) from here: http://www.oracle.com/technetwork/java/javaee/downloads/index.html
I have tried each of the solutions in the above posts and here: https://blogs.oracle.com/dipol/troubleshooting-glassfish-update-center
Including:
In the cmd prompt running set PKG_CLIENT_CONNECT_TIMEOUT=300 and set PKG_CLIENT_READ_TIMEOUT=300 before updatetool in C:\glassfish4\bin\updatetool.bat (c:\glassfish4 in my install directory - all settings were default, including install update tool...).
Set above mentioned timeout to much larger values - doesn't appear to make a difference at all, the process basically bombs immediately.
Running C:\glassfish4\bin\updatetool.bat many times.
Triple checking that I didn't somehow configure a proxy server in my sleep.
Use the update tool via the Glassfish admin console at http://localhost:4848 (seems to show no available update or add-ons, which seems odd..)
I get the following screenshot when I run C:\glassfish4\bin\updatetool.bat
I have no idea why the error would be proxy related, unless it happened to be something on their end. Interestingly, If I go directly to the URL mentioned (via Chrome) I get the following page:
What could possibly be going wrong here?
The updatetool was a commercial feature of Oracle GlassFish. Any update functionality relied on Oracle providing a site where updates could be hosted. Since Oracle GlassFish is no longer supported, this site no longer exists so the updatetool won't work any more.
Rather than downloading GlassFish from Oracle, you should download it from the official open source site, hosted on GitHub. Alternatively, if you really do need support, you could try Payara Server which is open source, and derived from GlassFish, but has support available (disclaimer: I work for Payara)

Incorrect times in application on ubuntu server

My application is online using ubuntu 14.04 / Apache2. My date command shows the proper EST time, but the app is using UTC. What am I missing that I need to change for my app to use the server time?
You are probably looking for https://secure.php.net/manual/en/function.date-default-timezone-set.php then.
In case of deadlinks, here's the gist of it:
<?php
date_default_timezone_set('America/Los_Angeles');
do_stuff_here();
?>

Why does JavaBridge work but JavaBridgeTemplate621 not

I am trying to install a PHP Java Bridge as per the instructions on http://php-java-bridge.sourceforge.net/pjb/index.php on Windows 7
I have PHP working fine on via IIS installed at c:\php
I copied the JavaBridge.war to c:\php which proved to get a good result from the test (running from c:\php)
java -classpath JavaBridge.war TestInstallation
I installed Tomcat 7 and copied the JavaBridge.war to webapps, which the service extract automatically and I am able to get the expected result from
http://localhost:8080/JavaBridge/
All Ok Great!
However when I do the same with the JavaBrigdeTemplate621.war, the browser
http://localhost:8080/JavaBridgeTemplate621/
returns an error
HTTP Status 500 - php.java.bridge.http.FCGIConnectException: Could not connect to server
I have not included the whole page as its very verbose, but the last root cause entry is
root cause
java.io.IOException: PHP not found. Please install php-cgi. PHP test command was: [php-cgi, -v]
php.java.bridge.Util$Process.start(Util.java:1145)
php.java.servlet.fastcgi.FCGIProcess.start(FCGIProcess.java:68)
php.java.bridge.http.NPChannelFactory.doBind(NPChannelFactory.java:94)
php.java.bridge.http.FCGIConnectionFactory.runFcgi(FCGIConnectionFactory.java:88)
php.java.bridge.http.FCGIConnectionFactory$1.run(FCGIConnectionFactory.java:109)
I've tried restarting IIS as well as Tomcat several times
What am I missing (It's Hot and it's Friday ....)
I notice that
\webapps\JavaBridgeTemplate621\WEB-INF\cgi\x86-windows
has a text file called php-cgi.exe.MISSING.README.txt
where as
\webapps\JavaBridge\WEB-INF\cgi\x86-windows
has php-cgi.exe, php5ts.dll and php.ini
Is there another manual step required to get those in there not documented in the instructions?
Not reading the instructions clearly enough. I missed that you should copy the automatically created folder (from war) into the IIS web apps folder. I was trying use Tomcat as the HTTP server instead of IIS. Once I copied them to IIS and accessed via default port 80 (not 8080) it worked fine.
Hope my conversation with myself is of benefit to someone else

cannot connect to genymotion and getting proxy error

I have dowloaded latest version of genymotion with proxy server 2.2.2 and while connecting i am getting invalid reply from server (do you use a proxy?). I am not using proxy for sure. Any ideas?
Answer, its all about the http proxy server on the genymotion settings just UNCHECK on the genymotion setting or remover the http proxy server by UN-ticking the ability to enter HTTP PROXY and PORT let it be blank by unckecking hence login your credentials, if it doesn't work try confirming you email with genymotion.
In my case I went to Settings > Network > I checked "Use HTTP Proxy" and I filled the Http Proxy and port fields (with company proxy valid values).
After that I connect smoothly as silk.
I had the same problem in ubuntu and after some struggle when i was almost giving up i stop the docker (had one instance running in port 3337 in my PC) and for my surprise it's finally work.
I had a similar issue (invalid reply from server without Proxy, on a highly customized and quite broken ubuntu 16.04). nothing of the above helped. (seemingly)
Then I visited this site:
http://qaru.site/questions/835901/genymotion-stuck-on-splash-screen
(well, you have to let google translate it, if you are not russian)
the error described there is completely different. (computer crash resulting in different networking issues)
but it had one thing in common with my case:
everything worked fine, and then suddenly: SOME NETWORKING ERROR - without reason
well, for me, the solution was the same as described on the russian page:
removing a (corrupted?!) conf file.
the conf file was at (my home folder)/.config/Genymobile/Genymotion.conf
i deleted it (i had to do it with root, because the file was owned by root, but this might have been the case because i messed a bit with genymotion...)
Then, i restarted genymotion and logged in again and it worked like a charm.
I had to allow Genymtion.exe in windows firewall. I'm using v3
Had the same problem, managed it using a VPN.

SIP Application on standalone Red5 Server does not connect to Asterisk Server

I have tried for days now trying to find the right version of red5phone, but to no avail. Also, I need red5 and asterisk to be on different servers. I have followed all instructions described in the various tutorials on web, but nothing helps. I have downloaded 2 different versions of red5phone: sip1, sip_47 from the red5phone google code site, but none of them worked!
When I use:
a) sip1 - shows the correct parameters being passed on the red5 server console, but connection is stuck up with the console displaying the following error:
[NioProcessor-1] ERROR o.r.server.service.ServiceInvoker - Method login with parameters [<sip user>, <sip user>,<sip user>,<sip user pwd>, <asterisk server i/p>, <asterisk server i/p>] not found in org.red5.server.webapp.sip.Application#2d0c94a7
b) sip47 - when I type in the values in the flex interface and check the red5 server console, I see all parameters correct(the ones I passed) except for asterisk server ip that i m trying to connect. Instead, it shows 127.0.0.1 by default and completely ignores the passed ip and regsitration fails.
I am using:
red5 server version: 0.9.1, centos: 4.8(final), red5phone used: sip_47 (tried sip1 as well)
As a desperate measure I tried debugging the source code for red5phone (java and flex files) myself. but when I try to create the environment on my local system, I get several compile errors for missing java packages such as javax.media, org.slf4j, org.red5, etc. really confused and desperate for some guidance. Any tips highly appreciated.
Sunil, I'm also new to this, I would try red5-voicebridge installed in your red5 server.
red5-voicebridge Please let me know if you got it to work.