windows下activemq啟動失敗問題:窗口一閃而逝、沒有報錯但是也沒有啟動成功、以及啟動端口被占用等問題

今天下載了activemq最新版本apache-activemq-5.15.2來玩玩,看著教程說的挺簡單的,不過等我解壓完畢雙擊activemq.bat文件啟動時候,彈出的命令窗口一閃而逝。。

最后去找到的解決辦法是自己打開命令窗口并且進入activemq的bin目錄,然后輸入activemq命令并且執(zhí)行,如下

D:\soft\apache-activemq-5.15.2\bin>activemq

不過并沒有啟動成功,也沒有報出錯誤,而是出現(xiàn)下面的一堆提示:

Usage: Main [--extdir <dir>] [task] [task-options] [task data]

Tasks:
    browse                   - Display selected messages in a specified destination.
    bstat                    - Performs a predefined query that displays useful statistics regarding the specified broker
    consumer                 - Receives messages from the broker
    create                   - Creates a runnable broker instance in the specified path.
    decrypt                  - Decrypts given text
    dstat                    - Performs a predefined query that displays useful tabular statistics regarding the specified destination type
    encrypt                  - Encrypts given text
    export                   - Exports a stopped brokers data files to an archive file
    list                     - Lists all available brokers in the specified JMX context
    producer                 - Sends messages to the broker
    purge                    - Delete selected destination's messages that matches the message selector
    query                    - Display selected broker component's attributes and statistics.
    start                    - Creates and starts a broker using a configuration file, or a broker URI.
    stop                     - Stops a running broker specified by the broker name.

Task Options (Options specific to each task):
    --extdir <dir>  - Add the jar files in the directory to the classpath.
    --version       - Display the version information.
    -h,-?,--help    - Display this help information. To display task specific help, use Main [task] -h,-?,--help

Task Data:
    - Information needed by each specific task.

于是再去找解決方案,最后發(fā)現(xiàn)是要輸入 activemq start 命令的,如下:

D:\soft\apache-activemq-5.15.2\bin>activemq start

這次是開始啟動了,不過卻報出了端口已經(jīng)被占用的錯誤,最終沒有啟動成功,錯誤信息如下:

java.io.IOException: Failed to bind to server socket: stomp://0.0.0.0:61616?maximumConnections=1000&wireFormat.maxFrameSize=104857600 due to: java.net.BindException: Address already in use:

然后我把端口號改成別的,依然是報錯,沒辦法就繼續(xù)百度解決辦法,最后找到的結(jié)果說是因為啟動了 Internet Connection Sharing (ICS)服務(wù)的原因,我想起了之前買了一個tplink無線網(wǎng)卡用來做無線熱點的設(shè)置中確實有啟動 Internet Connection Sharing (ICS)服務(wù)的步驟,于是就把這個服務(wù)關(guān)閉了,然后再次執(zhí)行 activemq start 命令,終于啟動成功了,不過有點麻煩的是無線熱點就不能用了,除非重新啟動該服務(wù)。

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容