IBM Mobilefirst CLI - Server start issue

2019-02-19 09:11发布

I recently installed IBM MobileFirst CLI on my Mac, but I don't seem to be able to start the Server. See error below. I searched the internet and found that there is a bug in JDK which causes the JavaLaunchHelper error. I downloaded the beta version that supposedly fixes the issue from here - JDK Download Link . But this doesn't help either. Any other help is appreciated.

Imayas-MBP:EmployeeDirectory imaya$ mfp start Initializing MobileFirst Console. objc[18564]: Class JavaLaunchHelper is implemented in both /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/bin/java and /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre/lib/libinstrument.dylib. One of the two will be used. Which one is undefined. Starting server worklight. Server worklight start failed. Check server logs for details. /Users/imaya/.ibm/mobilefirst/6.3.0/server/wlp/bin/server: line 744: 18563 Abort trap: 6 "${JAVA_CMD}" "$@" > "${JAVA_CMD_LOG}" 2>&1 Error: The MobileFirst server failed to start. The port may be in use by another instance of a running server, or the server may not exist.

2条回答
啃猪蹄的小仙女
2楼-- · 2019-02-19 09:45

The JavaLaunchHelper error is not the problem here; Anyone using Java 7 will experience it, but things will work regardless.

The problem here is the second error:

The MobileFirst server failed to start. The port may be in use by another instance of a running server, or the server may not exist.

Verify you do not have an already running server, that was started either by the CLI or by MFP Studio in an Eclipse installation.

  1. In the command line, run mfp stop
  2. In Eclipse, well, quit it
  3. Make sure the Java process is not running

Then, start over. Using the CLI, create a new project and application and try to start the server. For example:

  1. cd /Users/idanadar/Desktop
  2. mfp create testProject
  3. cd testProject
  4. mfp add hybrid testApp
  5. mfp start
  6. mfp build
  7. mfp deploy
  8. mfp console
查看更多
萌系小妹纸
3楼-- · 2019-02-19 09:49

On OSX, you can locate and kill a process holding open a port using the following:

Run (assumes port 10080):

$ lsof -i :10080

Then if a process is shown, run the following using the shown Process ID:

$ kill -9 {PID}

查看更多
登录 后发表回答