After connecting to windows azure through powershells I am executing hive query just to show the tables. But I am getting following error.
Invoke-Hive : The remote server returned an error: (403) Forbidden.
At line:1 char:13
+ $response = Invoke-Hive -Query #"
+ ~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Invoke-AzureHDInsightHiveJob], StorageException
+ FullyQualifiedErrorId : Microsoft.WindowsAzure.Storage.StorageException,Microsoft.WindowsAzure.Management.HDInsi
ght.Cmdlet.PSCmdlets.InvokeHiveCmdlet
Could you please guide me what to do ? I am using windows 7 OS Home premium , service pack 1
I am able to resolve this issue. This issue is related with system clock (laptop clock). I had to re-set my laptop clock as per my current time zone then I re-login through powershell to execute hive query and that went fine.
Related
Every time I Attempted to create a migration I am presented with the below error in Package Manager Console:
PM> Add-migration Initial
Build started...
Build succeeded.
Add-migration : Exception calling "Start" with "1" argument(s): "The specified executable is not a valid application for this OS platform."
At line:1 char:1
Add-migration Initial
+ CategoryInfo : NotSpecified: (:) [Add-Migration], MethodInvocationException
+ FullyQualifiedErrorId : Win32Exception,Add-Migration
adding -verbose gives me no further info.
Anyone got any idea on some of the common fixes for this?
Thanks
Trying to add a Network Security Group to a Log Analytics Workspace, getting the following error. This used to work in version 5.0.0 but no longer works with 5.0.1.
Set-AzureRmDiagnosticSetting -ResourceId $NsgFrontendSubnet.Id -WorkspaceId $LogAnalyticsWorkspace.ResourceId -Enabled $true -Categories 'NetworkSecurityGroupEvent','NetworkSecurityGroupRuleCounter'
Set-AzureRmDiagnosticSetting : Exception type: ErrorResponseException,
Message: The diagnostic setting 'service' doesn't exist., Code: ResourceNotFound, Status code:NotFound, Reason
phrase: Not Found At PAT0056-NetworkSecurityGroupNew:764 char:764
+
+ CategoryInfo : CloseError: (:) [Set-AzureRmDiagnosticSetting], PSInvalidOperationException
+ FullyQualifiedErrorId : Microsoft.Azure.Commands.Insights.Diagnostics.SetAzureRmDiagnosticSettingCommand
This seems to be a known bug reported on GitHub: https://github.com/Azure/azure-powershell/issues/6833
Only way to get around it is to revert to AzureRm.Insights 5.0.0
I have this ASP.NET Core project.
and the connection string that points to my SQL database.
"ConnectionStrings": {
"DefaultConnection": "Data Source=localhost;Initial Catalog=RestaurantDatabase;Integrated Security=True;Trusted_Connection=True;MultipleActiveResultSets=true"}
I need to initialize the database, thus run migration script. I've tried with update-database but that did not work.
What is the first step when initializing database from code?
UPDATE:
PM> dotnet ef migrations add InitialCreate
dotnet : No executable found matching command "dotnet-ef"
At line:1 char:1
+ dotnet ef migrations add InitialCreate
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (No executable f...and "dotnet-ef":String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
PM> Install-Package Microsoft.EntityFrameworkCore.Tools
CACHE https://api.nuget.org/v3/registration3-gz-semver2/microsoft.entityframeworkcore.tools/index.json
Restoring packages for E:\xxxx\Restaurant-App\src\Server\Restaurant.Server.Api\Restaurant.Server.Api.csproj...
Install-Package : NU1605: Detected package downgrade: Microsoft.EntityFrameworkCore.Design from 2.0.2 to 2.0.1. Reference the package directly from the project to select a
different version.
Restaurant.Server.Api -> Microsoft.EntityFrameworkCore.Tools 2.0.2 -> Microsoft.EntityFrameworkCore.Design (>= 2.0.2)
Restaurant.Server.Api -> Microsoft.EntityFrameworkCore.Design (>= 2.0.1)
At line:1 char:1
+ Install-Package Microsoft.EntityFrameworkCore.Tools
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
Install-Package : Package restore failed. Rolling back package changes for 'Restaurant.Server.Api'.
At line:1 char:1
+ Install-Package Microsoft.EntityFrameworkCore.Tools
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
PM> Add-Migration myMigration
Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[0]
User profile is available. Using 'C:\xxxx\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
infoinfo: IdentityServer4.Startup[0]
You are using the in-memory version of the persisted grant store. This will store consent decisions, authorization codes, refresh and reference tokens in memory only. If you are using any of those features in production, you want to switch to a different store implementation.
: IdentityServer4.Startup[0]
You are using the in-memory version of the persisted grant store. This will store consent decisions, authorization codes, refresh and reference tokens in memory only. If you are using any of those features in production, you want to switch to a different store implementation.
dbug: IdentityServer4.Startup[0]
Using Bearer as default scheme for authentication
Nuget packages
The script in question is this -> https://github.com/Jurabek/Restaurant-App
NOTE:
the Restaurant.Server.Api.csproj configured by DotNet command line not with Package Manager and also you don't need to create the initial migration.
you need to go to the src\Server\Restaurant.Server.Api>
run that commands with command line dotnet restore
and dotnet ef-database update
You have to first generate Migration by running Add-Migration YourMigrarionName from Package Manager console in Visual Studio and then run Update-Database to run the Migration on DB.
I'm new to the Package Manager Console. I have managed to install the KVM and am trying to create a migration in my ASP.NET 5 app.
When I run "k ef" I get the following exception:
k.cmd : System.ArgumentNullException: Value cannot be null.
At line:1 char:2
+ k <<<< ef
+ CategoryInfo : NotSpecified: (System.Argument...cannot be null.:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
Parameter name: appEnv
at Microsoft.Data.Entity.Utilities.Check.NotNull[T](T value, String parameterName)
at Microsoft.Data.Entity.Commands.Program..ctor(IServiceProvider serviceProvider, IApplic
ationEnvironment appEnv, ILibraryManager libraryManager)
I'm in the correct folder, and I have run kpm restore. I'm at a loss.
Switching dependency for EntityFramework.Commands from 7.0.0-* to 7.0.0-beta3 made it work.
Can anyone please help me to resolve this error?
Below is the weblogic server log...
I'm using Jdk 7, and Java Developer for ADF
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Unrecognized option: -jrockit
Process exited.
--Weblogic server log-------
*** Using HTTP port 7101 ***
*** Using SSL port 7102 ***
C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\DefaultDomain\bin\startWebLogic.cmd
[waiting for the server to complete its initialization...]
.
.
JAVA Memory arguments: -Xms256m -Xmx512m
.
WLS Start Mode=Development
.
CLASSPATH=C:\Oracle\Middleware\oracle_common\modules\oracle.jdbc_11.1.1\ojdbc6dms.jar;C:\Oracle\Middl
eware\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracle\Middleware\p
atch_jdev1112\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\PROGRA~1\Java\jdk1.7.0_67
\lib\tools.jar;C:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar;C:\Oracle\Middleware\wls
erver_10.3\server\lib\weblogic.jar;C:\Oracle\Middleware\modules\features\weblogic.server.modules_10.3
.5.0.jar;C:\Oracle\Middleware\wlserver_10.3\server\lib\webservices.jar;C:\Oracle\Middleware\modules\o
rg.apache.ant_1.7.1/lib/ant-all.jar;C:\Oracle\Middleware\modules\net.sf.antcontrib_1.1.0.0_1-
0b2/lib/ant-
contrib.jar;C:\Oracle\Middleware\oracle_common\modules\oracle.jrf_11.1.1\jrf.jar;C:\Oracle\Middleware
\wlserver_10.3\common\derby\lib\derbyclient.jar;C:\Oracle\Middleware\wlserver_10.3\server\lib\xqrl.jar
.
PATH=C:\Oracle\Middleware\patch_wls1035\profiles\default\native;C:\Oracle\Middleware\patch_jdev1112\p
rofiles\default\native;C:\Oracle\Middleware\wlserver_10.3\server\native\win\32;C:\Oracle\Middleware\w
lserver_10.3\server\bin;C:\Oracle\Middleware\modules\org.apache.ant_1.7.1\bin;C:\PROGRA~1\Java\jdk1.7
.0_67\jre\bin;C:\PROGRA~1\Java\jdk1.7.0_67\bin;E:\DB\app\oracle\product\11.2.0\server\bin;;c:\Program
Files\RSA SecurID Token Common;C:\Program Files\Intel\iCLS
Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell
\v1.0\;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program
Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program
Files\Java\jdk1.7.0_67\bin;C:\Oracle\Middleware\wlserver_10.3\server\native\win\32\oci920_8
.
***************************************************
* To start WebLogic Server, use a username and *
* password assigned to an admin-level user. For *
* server administration, use the WebLogic Server *
* console at http:\\hostname:port\console *
***************************************************
starting weblogic with Java version:
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Unrecognized option: -jrockit
Starting WLS with line:
C:\PROGRA~1\Java\jdk1.7.0_67\bin\java -jrockit -Xms256m -Xmx512m -Dweblogic.Name=DefaultServer
-Djava.security.policy=C:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic.policy -
Djavax.net.ssl.trustStore=C:\Users\inatar\AppData\Local\Temp\trustStore8547229804589400188.jks -
Doracle.jdeveloper.adrs=true -Dweblogic.nodemanager.ServiceEnabled=true -Xverify:none -da -
Dplatform.home=C:\Oracle\Middleware\wlserver_10.3 -
Dwls.home=C:\Oracle\Middleware\wlserver_10.3\server -
Dweblogic.home=C:\Oracle\Middleware\wlserver_10.3\server -Djps.app.credential.overwrite.allowed=true
-Dcommon.components.home=C:\Oracle\Middleware\oracle_common -Djrf.version=11.1.1 -
Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Jdk14Logger -
Ddomain.home=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\DefaultDomain -
Djrockit.optfile=C:\Oracle\Middleware\oracle_common\modules\oracle.jrf_11.1.1\jrocket_optfile.txt -
Doracle.server.config.dir=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\Defaul
tDomain\config\fmwconfig\servers\DefaultServer -
Doracle.domain.config.dir=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\Defaul
tDomain\config\fmwconfig -
Digf.arisidbeans.carmlloc=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\Defaul
tDomain\config\fmwconfig\carml -
Digf.arisidstack.home=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\DefaultDom
ain\config\fmwconfig\arisidprovider -
Doracle.security.jps.config=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\Defa
ultDomain\config\fmwconfig\jps-config.xml -
Doracle.deployed.app.dir=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\Default
Domain\servers\DefaultServer\tmp\_WL_user -Doracle.deployed.app.ext=\- -
Dweblogic.alternateTypesDirectory=C:\Oracle\Middleware\oracle_common\modules\oracle.ossoiap_11.1.1,C:
\Oracle\Middleware\oracle_common\modules\oracle.oamprovider_11.1.1 -
Djava.protocol.handler.pkgs=oracle.mds.net.protocol -Dweblogic.jdbc.remoteEnabled=false -
Dwsm.repository.path=C:\Users\inatar\AppData\Roaming\JDeveloper\system11.1.2.4.39.64.36.1\DefaultDoma
in\oracle\store\gmds -Dweblogic.management.discover=true -Dwlw.iterativeDev= - Dwlw.testConsole= -
Dwlw.logErrorsToConsole= -
Dweblogic.ext.dirs=C:\Oracle\Middleware\patch_wls1035\profiles\default\sysext_manifest_classpath;C:\O
racle\Middleware\patch_jdev1112\profiles\default\sysext_manifest_classpath weblogic.Server
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Unrecognized option: -jrockit
Process exited.
Unrecognized option: -jrockit Process exited. is the critical error. -jrockit is not an option available to the standard java jdk.
e.g. C:\PROGRA~1\Java\jdk1.7.0_67\bin\java -jrockit is the issue
Your JAVA_VENDOR is being set incorrectly in your setDomainEnv.cmd or startWebLogic.cmd script. It's being set to Oracle but should be set to Sun. You either need to figure out how that environment variable is being set incorrectly or manually fix one of the two .cmd files.
My last post was bad!
Here is the unwrapped set of lines I added:
echo "==> Force JAVA_VM to use -server:"
JAVA_VM=-server
export JAVA_VM
echo "."
echo "."
echo "JAVA Machine: ${JAVA_VM}"
THIS ISSUE IS RESOLVED FOR ME. I JUST WANTED TO POST THE SOLUTION SOMEWHERE...
I was working through exercise 1 on the NoSQL intro: http://www.oracle.com/technetwork/topics/bigdata/articles/intro-to-oracle-nosql-db-hol-1937059.pdf
I tried to deploy the Movieplex application to JDeveloper's internal weblogic server but kept getting hit with a -jrockit VM not found. This was difficult for me to get fixed because: 1 - I am not a heavy java programmer, and 2 - I apparently do not read very well. As for point 1, JRockit is an optimized special JAVA VM that some folks use. You can look that up oon line I guess, but it looks like we do not need it for this tutorial. As for point 2, I spent hours (I ashamedly admit) trying to figure out what .sh scripts were being run to start the Weblogic server running. I did all sorts of find commands, hunted through the binaries and folders underneath the Middleware folders. In the end, all I has to do was read the output log carefully, the script for me is: /home/oracle/.jdeveloper/system11.1.1.6.38.61.92/DefaultDomain/bin/startWebLogic.sh.
I edited the script REPLACING line 129 with below:
echo "==> Force JAVA_VM to use -server:"
JAVA_VM=-server
export JAVA_VM
echo "."
echo "."
echo "JAVA Machine: ${JAVA_VM}"
NOTE: there is another shell script that may be involved, /home/oracle/.jdeveloper/system11.1.1.6.38.61.92/Default/init-info/Domain