Weblogic Starting Configuration Wizard Failed With Error: "=="" was unexpected at this time - weblogic12c

I am trying to create a Domain in Weblogic server 12c.
While executing the script config.cmd at the path
C:\Oracle\Middleware12c\oracle_common\common\bin getting the error as "==" was unexpected at this time.
Have set JDK path while installing the weblogic server as below
set PATH=C:\Program Files\Java\jdk1.8.0_161\bin;%PATH%
set JAVA_HOME=C:\Program Files\Java\jdk1.8.0_161
Weblogic server is installed properly.

Display your PATH env var before starting the configuration wizard and check that the value is not enclosed with double quotes.

I have resolved this error by following steps
open the command line
echo %path%
then you can see all path variables
copy the result string into a notepad , then you can notice there are " characters
next remove those.
open the command line in the fmw_14.1.1.0.0_wls_lite_generic.jar folder
set path=double_quote_emoved_pathvariable
java -jar fmw_14.1.1.0.0_wls_lite_generic.jar

Related

Kafka error while running command to start zookeeper

I have kafka installed at following location
C:\Users\username\work\data\kafkadirectory\kafka\apache-kafka\kafka
Now, when I run following command at above location:
path/to/zookeeper-server-start.bat config\zookeeper.properties
I get error:
The input line is too long.
The syntax of the command is incorrect.
As can be seen, directory names don't include version(google search tells to get rid of version in directory names).
Still I face the issue.
Try the below-mentioned steps
Better to move the folder to short path 'C:\kafka\' (Reducing folder hierarchy)
Restart the command prompt to reset the classpath variable
Use PowerShell which have longer support to the classpath

mongod and mongo commands not working on windows 10

I've installed mongoDB on my windows 10 OS. Then I tried setting its database path to some directory by moving to it and typing mongod --datapath=data in cmd, where data is the folder which is to contain the db(I've used the relative path because I'm in that directory). But message comes that mongod is unrecognized command. After some searching I found that by specifying mongod path, i.e. "C:\Program Files\MongoDB\Server\3.4\bin\mongod.exe" --datapath=data works. Similar thing happens for mongo.
I want to directly run mongod and mongo commands, I have seen people directly using it(without going to the directory or specifying the path).
For a Windows installation, by default you have to use the full path to the exe unless you add it to the PATH.
To add it to the PATH:
01) Get path to bin, something like: C:\Program Files\MongoDB\Server\4.0\bin
02) Press the Windows key, type env, select Edit the system environment variables
03) On the Advanced tab, click Environment Variables
04) In the User variables for xxxx section, select path and then click the Edit... button
05) Click New and paste your path with a trailing slash, eg:
C:\Program Files\MongoDB\Server\4.0\bin\
06) Click OK, OK, OK and restart your command window.
Source
The examples you have seen are probably based on UNIX installations which I think by default install mongo as a service (which Windows doesn't) and that is what is called in those examples.
To simplify startup and configuration on Windows, you can also install it as a service. See the Mongo documentation here and the
"Configure Windows Service for MongoDB' section".
This will then allow you to start and stop Mongo by simply calling
net start MongoDB
Or
net stop MongoDB
If installed MongoDB version is 6.0 or above, mongo command will not work on Powershell/cmd. If you run the command you will get the following error:
'mongo' is not recognized as an internal or external command,
operable program or batch file.
To run mongo commands, you have to install MongoDB Shell from
After installing the shell, extract the zip file, you can rename the extracted folder (mongosh-1.6.0-win32-x64) as "MongoDB Shell" and move that folder to Windows(:C) > Program Files
Now open the folder, go to bin and copy the path:
C:\Program Files\MongoDB Shell\mongosh-1.6.0-win32-x64\bin (or
C:\Program Files\mongosh-1.6.0-win32-x64\mongosh-1.6.0-win32-x64\bin)
Go to
Settings > System > About > Advanced system settings > Environment
Variables > Under System Variables, click on 'Path' then 'Edit' >
Click 'New' and paste the above copied path > Click 'Ok' 'Ok' 'Ok'
Now open Powershell/cmd, run the command 'mongosh'
You're all set to work with MongoDB
To add it to the PATH:
Add Mongo’s bin folder to the Path Environment Variable
Kindly check the link:
here
After adding bin folder to the path Environment Variable
then simply type mongo in terminal it will start working
reference : Microsoft document
set your path like this
;C:\Program Files\MongoDB\Server\4.0\bin
this is worked for me.
Based on welshGaz answer above, I edited the User Path variable but it did not work for me yet. I wasn't able to access the System Path variables.
What I noticed from the errors on the command prompt is that it what missing the "C:\data\db" directory to store its files (I don't know what those files are for just yet). So I created that directory myself and it worked.
Same problem here. I installed through the .msi file provided for windows X64bit. In the installer instructions from MongoDB (https://docs.mongodb.com/manual/tutorial/install-mongodb-on-windows/), I read that you can add C:\Program Files\MongoDB\Server\4.2\bin to the System Path. Then it asks to omit the full path to the the MongoDB binaries. That is where I think some information is missing. How are we supposed to omit the full path to the MongoDB binaries?
Currently I can get MongoDB to run mongod using:
"C:\Program Files\MongoDB\Server\4.2\bin\mongod.exe" --dbpath="c:\data\db"
For --dbpath="c:\data\db" you can replace "c:\data\db" with the path to your database.
I can also run mongo using:
"C:\Program Files\MongoDB\Server\4.2\bin\mongo.exe"
Another reason to it if you enabled any property in YAML file and it is not formatted properly. YAML looks for specific syntax like colon":"+space" ".
E.g.-
security:
authorization: enabled
use mongosh command from your terminal. mongo command no longer works for 6.0 and above.
if you are trying to connect from connection url eg mongodb://localhost:27017/yourdb try changing it to something like mongodb://127.0.0.1/yourdb

how can i run the jboss server via windows commands without getting error

my java installed in C:\Program Files\Java\jdk1.7.0_01\bin
Jboss server installed in D:\jboss-as-7.1.1.Final\bin
Already i have set the environment variables for your reference.
C:\Python27\;C:\Python27\Scripts;C:\ProgramData\Oracle\Java\javapath;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Skype\Phone\;C:\Python27;C:\Python27\Scripts; C:\Program Files\Java\jdk1.7.0_01\bin
while i started to run the Jboss server7.1 via commands prompts getting error message "JAVA_HOME is not set".
Please provide me a solution
To overcome this message, set JAVA_HOME in standalone.conf.bat and domain.conf.bat file.
rem #
rem # Specify the location of the Java home directory (it is recommended that
rem # this always be set). If set, then "%JAVA_HOME%\bin\java" will be used as
rem # the Java VM executable; otherwise, "%JAVA%" will be used (see below).
rem #
set "JAVA_HOME=C:\Program Files\Java\jdk1.7.0_01\"

How to use Netbeans with PHPUnit on Vagrant?

I'm trying test my project using Netbeans (installed on Windows) and my server is located in a virtual machine (Virtualbox + Vagrant).
I saw this:
http://www.brianfenton.us/2012/03/running-phpunit-tests-on-vm-from.html#comment-form_4681337631658449555
But is not working and i got the error:
'sed' is not recognized as an internal or external command, operable program or batch file.
Here ismy config:
:: remote serveur PuTTY silent connection (auto-login, key authentication with pageant)
set REMOTE_SERVER=vagrant#dev
:: root path of all local netbeans projects, despecialized for sed
set LOCAL_WORKSPACE=D:\/www
:: remote path of all projects, despecialized for sed
set REMOTE_WORKSPACE=\/var\/www
:: remote location of NetBeansSuite.php
set REMOTE_NETBEANSSUITE=\/usr\/local\/share\/php\/phpunit\/NetBeansSuite.php
... but i don't know what to do with:
set REMOTE_NETBEANSSUITE=\/usr\/local\/share\/php\/phpunit\/NetBeansSuite.php
Sorry for my english.
sed is the "Stream EDitor" Unix command-line utility, and the comment with the batch file on that article you linked says you need to install it on Windows.
Sorry, I don't know why the batch file uses a test suite to run the test when the original shell script did not. :(

Executing subprocess.Popen inside Python script in PyDev context is different than running in terminal

I'm executing this code:
p = subprocess.Popen(['/path/to/my/script.sh','--flag'] , stdin=subprocess.PIPE)
p.communicate(input='Y')
p.wait()
It works when executing it on the shell using "python scriptName.py",
BUT when executing using PyDev in Eclipse, it fails, the reason:
/path/to/my/script.sh: line 111: service: command not found
This bash script "script.sh" contains the following command which causes the error:
service mysqld restart
So "service" is not recognized when running the .sh script from the context of PyDev.
I guess it has to do with some ENV VAR configurations, couldn't find how to do it.
BTW - Using "shell=True" when calling subprocess.Popen didn't solve it.
service usually is located in /usr/sbin, and that this directory isn't on the PATH. As this usually contains administrative binaries and scripts which arn't designed to be run by everyone (only by admins/root), the sbin directories arn't always added to the PATH by default.
To check this, try to print PATH in your script (or add an env command).
To fix it, you could either
set the PATH in your python script using os.setenv
pass an env dict containing the correct PATH to Popen
set the PATH in your shellscript
use the full path in your shellscript
set the PATH in eclipse