how to solve “ DeprecationWarning: 'GLOBAL' is deprecated, use global ” when deploy node application with passenger+nginx

859 views
Skip to first unread message

miffy ye

unread,
Nov 24, 2016, 11:51:10 AM11/24/16
to Phusion Passenger Discussions
  1. My node application can run normaly when i was in development mode. Simply use "npm start" to run it and i could visit my app through "http://localhost:3000"
  2. But when i deploy my node application with nginx+passenger, i meet this error,the detailed infomation is list as below.
  3. I notice the key information must be " DeprecationWarning: 'GLOBAL' is deprecated, use 'global'", but i don't know what does it refer to, because i can't found 'GLOBAL' in my code files;
  4. I am sure the passenger was sucessfully installed and worked normally,because i could run other simple node apolication through it but not my app,i don't know why......
  5. I have struggled for the problems for many many hours and serched google for anwers, hope you can give me some useful infomation, thanks very much!

    [the error info][1] [1]: https://i.stack.imgur.com/0N87B.png

    - information

    Web application could not be started An error occurred while starting the web application: it did not write a startup response in time. Please read this article for more information about this problem. Raw process output:

    (node:12671) DeprecationWarning: 'GLOBAL' is deprecated, use 'global' Error ID ef585c1b Application root /var/www/microblog/myblog Environment (value of RAILS_ENV, RACK_ENV, WSGI_ENV, NODE_ENV and PASSENGER_APP_ENV) development User and groups uid=0(root) gid=0(root) groups=0(root) Environment variables XDG_SESSION_ID=55 COMP_WORDBREAKS=
    "'><;|&(: TERM=xterm-256color SHELL=/bin/bash SSH_CLIENT=27.46.7.216 5816 22 SSH_TTY=/dev/pts/3 USER=root LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:.tar=01;31:.tgz=01;31:.arj=01;31:.taz=01;31:.lzh=01;31:.lzma=01;31:.tlz=01;31:.txz=01;31:.zip=01;31:.z=01;31:.Z=01;31:.dz=01;31:.gz=01;31:.lz=01;31:.xz=01;31:.bz2=01;31:.bz=01;31:.tbz=01;31:.tbz2=01;31:.tz=01;31:.deb=01;31:.rpm=01;31:.jar=01;31:.war=01;31:.ear=01;31:.sar=01;31:.rar=01;31:.ace=01;31:.zoo=01;31:.cpio=01;31:.7z=01;31:.rz=01;31:.jpg=01;35:.jpeg=01;35:.gif=01;35:.bmp=01;35:.pbm=01;35:.pgm=01;35:.ppm=01;35:.tga=01;35:.xbm=01;35:.xpm=01;35:.tif=01;35:.tiff=01;35:.png=01;35:.svg=01;35:.svgz=01;35:.mng=01;35:.pcx=01;35:.mov=01;35:.mpg=01;35:.mpeg=01;35:.m2v=01;35:.mkv=01;35:.webm=01;35:.ogm=01;35:.mp4=01;35:.m4v=01;35:.mp4v=01;35:.vob=01;35:.qt=01;35:.nuv=01;35:.wmv=01;35:.asf=01;35:.rm=01;35:.rmvb=01;35:.flc=01;35:.avi=01;35:.fli=01;35:.flv=01;35:.gl=01;35:.dl=01;35:.xcf=01;35:.xwd=01;35:.yuv=01;35:.cgm=01;35:.emf=01;35:.axv=01;35:.anx=01;35:.ogv=01;35:.ogx=01;35:.aac=00;36:.au=00;36:.flac=00;36:.mid=00;36:.midi=00;36:.mka=00;36:.mp3=00;36:.mpc=00;36:.ogg=00;36:.ra=00;36:.wav=00;36:.axa=00;36:.oga=00;36:.spx=00;36:.xspf=00;36: MAIL=/var/mail/root PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games PWD=/var/www/microblog/myblog LANG=en_US.UTF-8 NODE_PATH=/usr/share/passenger/node SHLVL=1 HOME=/root LANGUAGE=en_US: LOGNAME=root SSH_CONNECTION=27.46.7.216 5816 123.57.243.29 22 LESSOPEN=| /usr/bin/lesspipe %s XDG_RUNTIME_DIR=/run/user/0 LESSCLOSE=/usr/bin/lesspipe %s %s _=/usr/bin/passenger OLDPWD=/var/www/microblog PASSENGER_LOCATION_CONFIGURATION_FILE=/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini PASSENGER_USE_FEEDBACK_FD=true UID=0 SERVER_SOFTWARE=nginx/1.10.1 Phusion_Passenger/5.0.30 PASSENGER_DEBUG_DIR=/tmp/passenger.spawn-debug.XXXXu3bFF4 IN_PASSENGER=1 PYTHONUNBUFFERED=1 RAILS_ENV=development RACK_ENV=development WSGI_ENV=development NODE_ENV=development PASSENGER_APP_ENV=development Ulimits Unknown System metrics ------------- General ------------- Kernel version : 3.13.0-86-generic Uptime : 1d 13h 59m 14s Load averages : 0.07%, 0.07%, 0.06% Fork rate : unknown

    ------------- CPU ------------- Number of CPUs : 1 Average CPU usage : 0% -- 0% user, 0% nice, 0% system, 100% idle CPU 1 : 0% -- 0% user, 0% nice, 0% system, 100% idle I/O pressure : 0% CPU 1 : 0% Interference from other VMs: 0% CPU 1 : 0%

    ------------- Memory ------------- RAM total : 992 MB RAM used : 224 MB (23%) RAM free : 767 MB Swap total : 0 MB Swap used : 0 MB (-nan%) Swap free : 0 MB Swap in : unknown

    Swap out : unknown

Daniel Knoppel

unread,
Nov 24, 2016, 2:10:21 PM11/24/16
to Phusion Passenger Discussions
Hi,

The DeprecationWarning is not important.  It's just a warning.

The real error is as Passenger tells you in the beginning:
Web application could not be started An error occurred while starting the web application: it did not write a startup response in time. <====

It means your application didn't start fast enough. Maybe it's hanging (waiting for some other third party service?), or maybe you know that it's slow and it needs more time. The start timeout is controlled with this setting: https://www.phusionpassenger.com/library/config/nginx/reference/#passenger_start_timeout

- Daniel

miffy ye

unread,
Nov 25, 2016, 12:39:06 AM11/25/16
to Phusion Passenger Discussions
ah!!!thanks for your information, it helps a lot!!! I have checked my application files, i didn't use third part API/CDN etc, i put my jq.js and bootstrap.js in my javascript files. and my application can be acceesed very quickly through localhost:3000 in my server, is it still the speed of the application that matters?

miffy ye

unread,
Nov 25, 2016, 1:49:43 AM11/25/16
to phusion-...@googlegroups.com
``

miffy ye

unread,
Nov 25, 2016, 2:06:23 AM11/25/16
to Phusion Passenger Discussions
hi, I haven't solved the problem yet, there are more detailed infomation:

[ 2016-11-25 14:40:11.9997 22264/7ffa4d357700 age/Ust/UstRouterMain.cpp:422 ]: Signal received. Gracefully shutting down... (send $

[ 2016-11-25 14:40:11.9998 22264/7ffa53b647c0 age/Ust/UstRouterMain.cpp:492 ]: Received command to shutdown gracefully. Waiting un$

[ 2016-11-25 14:40:11.9998 22264/7ffa4cb56700 Ser/Server.h:817 ]: [UstRouterApiServer] Freed 0 spare client objects

[ 2016-11-25 14:40:11.9998 22264/7ffa4cb56700 Ser/Server.h:464 ]: [UstRouterApiServer] Shutdown finished

[ 2016-11-25 14:40:12.0000 22264/7ffa4d357700 Ser/Server.h:464 ]: [UstRouter] Shutdown finished

[ 2016-11-25 14:40:12.0001 22264/7ffa53b647c0 age/Ust/UstRouterMain.cpp:523 ]: Passenger UstRouter shutdown finished

[ 2016-11-25 14:40:13.0439 22418/7f306cf827c0 age/Wat/WatchdogMain.cpp:1291 ]: Starting Passenger watchdog...

[ 2016-11-25 14:40:13.0505 22421/7fa68b3be7c0 age/Cor/CoreMain.cpp:982 ]: Starting Passenger core...

[ 2016-11-25 14:40:13.0507 22421/7fa68b3be7c0 age/Cor/CoreMain.cpp:235 ]: Passenger core running in multi-application mode.

[ 2016-11-25 14:40:13.0523 22421/7fa68b3be7c0 age/Cor/CoreMain.cpp:732 ]: Passenger core online, PID 22421

[ 2016-11-25 14:40:13.0603 22426/7f5e4e23c7c0 age/Ust/UstRouterMain.cpp:529 ]: Starting Passenger UstRouter...

[ 2016-11-25 14:40:13.0611 22426/7f5e4e23c7c0 age/Ust/UstRouterMain.cpp:342 ]: Passenger UstRouter online, PID 22426

App 22449 stdout:


[ 2016-11-25 14:40:42.0071 22414/7ff1b94817c0 age/Wat/WatchdogMain.cpp:478 ]: Some Phusion Passenger agent processes did not exit in time, forcefully shutting down a$

[ 2016-11-25 14:41:17.7887 22421/7fa6843ea700 age/Cor/App/Implementation.cpp:304 ]: Could not spawn process for application /var/www/microblog/myblog: An error occur$


  Message from application: An error occurred while starting the web application: it did not write a startup response in time. Please read <a href="https://github.co$



On Friday, November 25, 2016 at 3:10:21 AM UTC+8, Daniel Knoppel wrote:

Camden Narzt

unread,
Nov 28, 2016, 6:01:10 PM11/28/16
to Phusion Passenger Discussions
If you include the contents of your passenger config and package.json file, I'll take a look at them.
Reply all
Reply to author
Forward
0 new messages