How to specify a timezone in EMR while launching - amazon-ec2

I am writing a "create EMR" script and I want it to set the default timezone to CST. Is my configuration correct?
"Configurations": [{"Classification":"core-site",
"Properties":{"io.compression.codec.lzo.class":"",
"io.compression.codecs":"org.apache.hadoop.io.compress.GzipCodec,org.apache.hadoop.io.compress.DefaultCodec,\
org.apache.hadoop.io.compress.BZip2Codec,org.apache.hadoop.io.compress.SnappyCodec"}},
"Configurations": [{"Classification":"export","Properties":{"TZ":"US/Central"}}] ]
Error: botocore.exceptions.ClientError: An error occurred (ValidationException) when calling the RunJobFlow operation: Classification 'export' is not valid for parent classification 'core-site'.

Related

Bad configuration in Logstash - Windows 11

I try execute input jdbc oracle with tracking column, but don't work, need other information? like file.conf, etc.?
D:\Elastic\logstash-8.6.0>.\bin\logstash.bat -f D:\Elastic\logstash-8.6.0\config\conf.d\bo_firmas_electronicas.conf
Using LS_JAVA_HOME defined java: C:\Program Files\Java\jdk-19
"WARNING: Logstash comes bundled with the recommended JDK(), but is overridden by the version defined in LS_JAVA_HOME. Consider clearing LS_JAVA_HOME to use the bundled JDK."
Sending Logstash logs to D:\Elastic\logstash-8.6.0\logs which is now configured via log4j2.properties
[2023-01-13T15:00:09,087][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"Java::JavaLang::IllegalStateException", :message=>"Unable to configure plugins: (ArgumentError) Cannot determine timezone from nil\n(secs:1673640004.484,utc~:\"2023-01-13 20:00:04.48399996757507324\",ltz~:nil)\n(etz:nil,tnz:\"PET\",tziv:\"2.0.5\",tzidv:\"1.2022.6\",rv:\"2.6.8\",rp:\"java\",win:true,rorv:nil,astz:nil,eov:\"1.2.7\",eotnz:\"???\",eotnfz:\"???\",eotlzn:\"???\",\ndebian:nil,centos:nil,osx:nil)\nTry setting `ENV['TZ'] = 'Continent/City'` in your script (see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones)", :backtrace=>["org.logstash.config.ir.CompiledPipeline.<init>(CompiledPipeline.java:120)", "org.logstash.execution.AbstractPipelineExt.initialize(AbstractPipelineExt.java:181)", "org.logstash.execution.AbstractPipelineExt$INVOKER$i$initialize.call(AbstractPipelineExt$INVOKER$i$initialize.gen)", "org.jruby.internal.runtime.methods.JavaMethod$JavaMethodN.call(JavaMethod.java:846)", "org.jruby.ir.runtime.IRRuntimeHelpers.instanceSuper(IRRuntimeHelpers.java:1229)", "org.jruby.ir.instructions.InstanceSuperInstr.interpret(InstanceSuperInstr.java:131)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:361)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.INTERPRET_METHOD(MixedModeIRMethod.java:128)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:115)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:329)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:87)", "org.jruby.RubyClass.newInstance(RubyClass.java:911)", "org.jruby.RubyClass$INVOKER$i$newInstance.call(RubyClass$INVOKER$i$newInstance.gen)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:329)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:87)", "org.jruby.ir.instructions.CallBase.interpret(CallBase.java:549)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:361)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.ir.interpreter.InterpreterEngine.interpret(InterpreterEngine.java:92)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.INTERPRET_METHOD(MixedModeIRMethod.java:238)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:225)", "org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:226)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:393)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:206)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:325)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.ir.interpreter.Interpreter.INTERPRET_BLOCK(Interpreter.java:116)", "org.jruby.runtime.MixedModeIRBlockBody.commonYieldPath(MixedModeIRBlockBody.java:136)", "org.jruby.runtime.IRBlockBody.call(IRBlockBody.java:66)", "org.jruby.runtime.IRBlockBody.call(IRBlockBody.java:58)", "org.jruby.runtime.Block.call(Block.java:143)", "org.jruby.RubyProc.call(RubyProc.java:309)", "org.jruby.internal.runtime.RubyRunnable.run(RubyRunnable.java:107)", "java.base/java.lang.Thread.run(Thread.java:1589)"]}
[2023-01-13T15:00:09,121][FATAL][org.logstash.Logstash ] Logstash stopped processing because of an error: (SystemExit) exit
org.jruby.exceptions.SystemExit: (SystemExit) exit
at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:790) ~[jruby.jar:?]
at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:753) ~[jruby.jar:?]
at D_3a_.Elastic.logstash_minus_8_dot_6_dot_0.lib.bootstrap.environment.<main>(D:\Elastic\logstash-8.6.0\lib\bootstrap\environment.rb:91) ~[?:?]
D:\Elastic\logstash-8.6.0>
D:\Elastic\logstash-8.6.0>.\bin\logstash.bat -f D:\Elastic\logstash-8.6.0\config\conf.d\bo_firmas_electronicas.conf
Using LS_JAVA_HOME defined java: C:\Program Files\Java\jdk-19
"WARNING: Logstash comes bundled with the recommended JDK(), but is overridden by the version defined in LS_JAVA_HOME. Consider clearing LS_JAVA_HOME to use the bundled JDK."
Sending Logstash logs to D:\Elastic\logstash-8.6.0\logs which is now configured via log4j2.properties
[2023-01-13T15:02:00,714][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"Java::JavaLang::IllegalStateException", :message=>"Unable to configure plugins: (ArgumentError) Cannot determine timezone from nil\n(secs:1673640115.819,utc~:\"2023-01-13 20:01:55.8190000057220459\",ltz~:nil)\n(etz:nil,tnz:\"PET\",tziv:\"2.0.5\",tzidv:\"1.2022.6\",rv:\"2.6.8\",rp:\"java\",win:true,rorv:nil,astz:nil,eov:\"1.2.7\",eotnz:\"???\",eotnfz:\"???\",eotlzn:\"???\",\ndebian:nil,centos:nil,osx:nil)\nTry setting `ENV['TZ'] = 'Continent/City'` in your script (see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones)", :backtrace=>["org.logstash.config.ir.CompiledPipeline.<init>(CompiledPipeline.java:120)", "org.logstash.execution.AbstractPipelineExt.initialize(AbstractPipelineExt.java:181)", "org.logstash.execution.AbstractPipelineExt$INVOKER$i$initialize.call(AbstractPipelineExt$INVOKER$i$initialize.gen)", "org.jruby.internal.runtime.methods.JavaMethod$JavaMethodN.call(JavaMethod.java:846)", "org.jruby.ir.runtime.IRRuntimeHelpers.instanceSuper(IRRuntimeHelpers.java:1229)", "org.jruby.ir.instructions.InstanceSuperInstr.interpret(InstanceSuperInstr.java:131)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:361)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.INTERPRET_METHOD(MixedModeIRMethod.java:128)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:115)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:329)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:87)", "org.jruby.RubyClass.newInstance(RubyClass.java:911)", "org.jruby.RubyClass$INVOKER$i$newInstance.call(RubyClass$INVOKER$i$newInstance.gen)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:329)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:87)", "org.jruby.ir.instructions.CallBase.interpret(CallBase.java:549)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:361)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.ir.interpreter.InterpreterEngine.interpret(InterpreterEngine.java:92)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.INTERPRET_METHOD(MixedModeIRMethod.java:238)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:225)", "org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:226)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:393)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:206)", "org.jruby.ir.interpreter.InterpreterEngine.processCall(InterpreterEngine.java:325)", "org.jruby.ir.interpreter.StartupInterpreterEngine.interpret(StartupInterpreterEngine.java:72)", "org.jruby.ir.interpreter.Interpreter.INTERPRET_BLOCK(Interpreter.java:116)", "org.jruby.runtime.MixedModeIRBlockBody.commonYieldPath(MixedModeIRBlockBody.java:136)", "org.jruby.runtime.IRBlockBody.call(IRBlockBody.java:66)", "org.jruby.runtime.IRBlockBody.call(IRBlockBody.java:58)", "org.jruby.runtime.Block.call(Block.java:143)", "org.jruby.RubyProc.call(RubyProc.java:309)", "org.jruby.internal.runtime.RubyRunnable.run(RubyRunnable.java:107)", "java.base/java.lang.Thread.run(Thread.java:1589)"]}
[2023-01-13T15:02:00,748][FATAL][org.logstash.Logstash ] Logstash stopped processing because of an error: (SystemExit) exit
org.jruby.exceptions.SystemExit: (SystemExit) exit
at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:790) ~[jruby.jar:?]
at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:753) ~[jruby.jar:?]
at D_3a_.Elastic.logstash_minus_8_dot_6_dot_0.lib.bootstrap.environment.<main>(D:\Elastic\logstash-8.6.0\lib\bootstrap\environment.rb:91) ~[?:?]`
According to your logs, your problem is related with timestamp issue :
Unable to configure plugins: (ArgumentError) Cannot determine timezone from nil\n(secs:1673640004.484,utc~:\"2023-01-13 20:00:04.48399996757507324\",ltz~:nil)\n(etz:nil,tnz:\"PET\",tziv:\"2.0.5\",tzidv:\"1.2022.6\",rv:\"2.6.8\",rp:\"java\",win:true,rorv:nil,astz:nil,eov:\"1.2.7\",eotnz:\"???\",eotnfz:\"???\",eotlzn:\"???\",\ndebian:nil,centos:nil,osx:nil)\nTry setting `ENV['TZ'] = 'Continent/City'` in your script (see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones)
And, you can easily find similar questions are here:
https://discuss.elastic.co/t/i-get-error-unable-to-configure-plugins-argumenterror-cannot-determine-timezone-from-nil/319531
Logstash 8.0 #timestamp with nanoseconds precision
https://discuss.elastic.co/t/nanoseconds-with-logstash-and-elasticsearch/282492
So, I think this answer you need to put inside the your pipeline too:
https://stackoverflow.com/a/70804574/721600

There is no .trace file found for performance profile ‘Leaks’

Following this example and using Javascript, get the following error when run my tests. The error is generated on the following command:
enter code heredriver.executeScript('mobile: stopPerfRecord', [
{ profileName: 'Leaks' },
]);
Error:
Got this error “Request failed with status 500 due to An unknown server-side error occurred while processing the command. Original error: There is no .trace file found for performance profile ‘Time Profiler’ and device XXXX. Make sure the selected profile is supported on this device”

Unable to import EC2 instance with pulumi import command

I am running an EC2 instance on aws which I need to import to pulumi by running the following command pulumi import -f resources.json.
I have the following JSON file as my resource file resource.json.
{
"resources": [{
"type": "aws:ec2/instance:Instance",
"name": "my-server",
"id": "i-08f92a261a2ef6650",
"ami": "ami-0fdb3f3ff5d7c40db"
}
]
}
But get the following error:
aws:ec2:Instance (my-server):
error: aws:ec2/instance:Instance resource 'my-server' has a problem: Missing required argument: "instance_type": one of `instance_type,launch_template` must be specifie
d. Examine values at 'Instance.InstanceType'.
error: aws:ec2/instance:Instance resource 'my-server' has a problem: Missing required argument: "launch_template": one of `ami,instance_type,launch_template` must be sp
ecified. Examine values at 'Instance.LaunchTemplate'.
error: aws:ec2/instance:Instance resource 'my-server' has a problem: Missing required argument: "ami": one of `ami,launch_template` must be specified. Examine values at
'Instance.Ami'.
error: Preview failed: one or more inputs failed to validate
This is a bug, please see this GitHub issue:
https://github.com/pulumi/pulumi-aws/issues/1605
and this one: https://github.com/pulumi/pulumi/issues/7160#issuecomment-912093311
The best workaround at this stage is to define the EC2 instance in your code, and then set the import resource property as defined here

Kibana 4.4.2 Environment variable in config file

Edit For anyone wanting updates, here is a link to the issue I created to hopefully get this added:
https://github.com/elastic/kibana/issues/6688
When I setup Elasticsearch I can have entries in the config file that reference environment variables (this is on RHEL - Linux):
var.name: ${ENV_VAR}/something
This works for Elasticsearch.
I want to do the same for Kibana:
logging.dest: ${ELK_HOME}/log/kibana.log
Problem is, in this case I get an error:
events.js:141
throw er; // Unhandled 'error' event
^
Error: ENOENT: no such file or directory, open '${ELK_HOME}/log/kibana.log'
at Error (native)
Finished
Any ideas how I make the Kibana kibana.yml config file use environment variables?

Error while connecting Elastic Map Reduce ruby client

I am following the steps mentioned on the AWS to use an interactive Hive session using SSH.
I used the following resources
https://github.com/ucbtwitter/getting-started/wiki/Using-Elastic-Map-Reduce-via-Command-Line
http://docs.amazonwebservices.com/ElasticMapReduce/latest/GettingStartedGuide/SignUp.html
I was getting this error initially "Error: Missing key access-id" and then I fixed my JSON file. The JSON file is in the same format as mentioned in the above links.
When I run this command
./elastic-mapreduce
I am getting the following error :-
Error: Unable to parse credentials.json: can't convert String into Integer.
I checked the values required in JSON at AWS as well.
Does anyone has an idea why am I getting this error?
The region value in the credentials.json must be of int type.
{......
......
"region": 1
}

Resources