w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
cdh4.3,Exception from the logs ,after ./start-dfs.sh ,datanode and namenode start fail
There seems to be a Name Resolution issue. Datanode denied communication with namenode: DatanodeRegistration(0.0.0.0, storageID=DS-30209445-192.168.2.41-50010-1371109358645, infoPort=50075, ipcPort=50020, Here DataNode is identifying itself as 0.0.0.0. Looks like dfs.hosts enforcement. Can you recheck on your NameNode's hdfs-site.xml configs that you are surely not using a dfs.hosts file? This error may arise if the datanode that is trying to connect to the namenode is either listed in the file defined by dfs.hosts.exclude or that dfs.hosts is used and that datanode is not listed within that file. Make sure the datanode is not listed in excludes, and if you are using dfs.hosts, add it to the includes. Restart hadoop after that and run hadoop dfsadmin -refreshNodes. HTH

Categories : Hadoop

Setting start levels & auto-start of Eclipse plug-ins: p2.inf vs product definition
It really comes down to a personal preference. The product level is the ultimate final artifact most of the time. As you discovered, it has much better tooling integration. When the product is assembled by Tycho or PDE Build you'll know exactly what's in it and what needs to be started for it in order to work properly. However, sometimes it doesn't feel right to go down to the bundle granularity level in product definitions especially when it's composed of features only. But defining start properties at the feature level or even at the bundle level can be tricky, though. For example, when someone consumes your features/bundles in another product they might have different auto-start/start-level requirements. FWIW, the p2.inf file isn't outdated at all. It's the raw bare metal to modify/op

Categories : Eclipse

ac-auto-start (auto-complete mode) would not get set no matter what
There is indeed something strange going on with the setting of auto-complete-mode. (I'm using the ELPA version in a GNU Emacs 24.3.1) This is set up by customize-group RET auto-complete : '(ac-auto-show-menu t) '(ac-auto-start t) At this point if you M-x auto-complete-mode you get a [no match] right in the minibuffer. Only after you try to M-x auto-complete, yelding a "auto-complete-mode is not enabled" weird error, will you be able to M-x auto-complete-mode (but without command completion... Hm) and then be in the mode. If you put this in your init file (.emacs) (require 'auto-complete) (auto-complete-mode t) It will be effective only if you re-eval it after startup (?!?). The same with something like (if (auto-complete) (auto-complete-mode t)) The only way that I found

Categories : Emacs

Auto-scrolling multiple chat logs using AngularJS
You could create a chatlog directive and add it to your markup like this: <div chatlog ng-repeat="msg in channel.msgLog"> Then in the linking function of your directive you can do something like: link: function(scope, element, attrs) { if (scope.$last) { // this will run each time the channel.msgLog array changes // more precisely, every time the last element is linked } }

Categories : Angularjs

Web Deploy Command Line Logs in Event Logs (Updated / Inserted / Deleted Files) in event logs
I don't believe you can log the activities to the event log, but what you can do is use the -xml parameter to output the changes in XML format. You could then use this to log to the event log via a Powershell script, for example.

Categories : Iis

Where to start with Deprecated: Directive 'safe_mode' on line 0 in Apache error logs
Safe_mode is a PHP feature that has been depreciated in 5.3 and ultimately removed in 5.4. It is pointless and potentially dangerous and should not be used. To turn it off go to your php.ini file and change safe_mode = on to safe_mode = off Restart apache and you should be good to go.

Categories : Apache

How to conveniently store common logs and client specific logs
I would have an xml file that contain the appenders to specify what packages go into what log file. You can then load the xml file in your application entry point. Below is an example I have used in my current project <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"> <!-- appenders --> <appender name="console" class="org.apache.log4j.ConsoleAppender"> <param name="Target" value="System.out" /> <param name="threshold" value="error" /> <layout class="org.apache.log4j.PatternLayout"> <param name="ConversionPattern" value="[%t] %p %c - %m%n" /> </layout> </appender> <appender name="codebaseXAppender" class="org.apache.log4j.RollingFileAppender"> <

Categories : Java

IIS 7.5 Auto Start Not working with Ninject using Web Activator
Ok, i just had a similar problem. Ninject didn't register when I ran the application on my local IIS (7.5), in IIS Express however, it worked fine. The problem was that I had batch="false" in my compilation node in web.config. Setting batch to true (which is the default) solved the problem.

Categories : Dotnet

Best Place to Put "Auto Start" another activity code?
My suggestion will be to use the method onPause of the activity in application A and set a flag there "application B was called". Then if this flag is set do not call application B in onCreate of the activity in Application A and unset the flag. If application B is too long in the foreground application A might be suspended by the system and the flag will be reset. In such case maybe it is good idea to have the flag stored in some persistent storage (e.g. SharedPreferences). EDIT One more thing: the flag should be set in onPause only if the activity is being paused, because the other application will be shown (this will be easily determinable, because everything happens in the same class).

Categories : Android

Auto-start appfabric seems to work sequentially
There is no priority in AppFabric Auto Start feature. You can't assume that one service will always be started before the others. Also, you can't assume they will start all at the same time. For the specific scenario, it's recommanded to use WCF 4.0 Discovery and Announcement. Announcement feature enables service to announce their availability (by sending Hello and Bye announcements) whereas Discovery feature allow clients to discover service address at runtime. All your services are on the same server ? could be pertinent to use a namedPipeBinding.

Categories : Wcf

IIS Auto-Start not disabling Idle Timeout
(http://developers.de/blogs/damir_dobric/archive/2009/10/11/iis-7-5-and-always-running-web-applications.aspx) i have struggled a lot in this issue. I did everything i could to keep my services alive in IIS but eventually got tired and had to take different approach. I created a windows service just to keep those app pool alive. One approach you can try is go to IIS config file and verify that you can see the configuration you made is reflected in that config file. Refer to the link on top. But your configuration will be reset on app pool restart whatever time you set it to go to sleep. You might need to comeup with some approach.

Categories : Asp Net

Twitter bootstrap carousel does not auto start
Try to give your Carousel an id and try this $('#myCarousel').carousel({ // For Carousel Image Slider interval: 6000, cycle: true, }).trigger('slid'); myCarousel = id of carousel

Categories : Javascript

Have BroadcastReceiver run as Service in the background + Auto Start after boot
To start your service on BOOT_COMPLETED event and to receive SMS intent continuously. AndroidManifest.xml: <receiver android:name="BootReceiver" > <intent-filter> <action android:name="android.intent.action.BOOT_COMPLETED" /> </intent-filter> </receiver> BootReceiver.java: public class BootReceiver extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Intent service = new Intent(context, SMSService.class); context.startService(service); } } SMSService.java: public class SMSService extends IntentService { @Override protected void onHandleIntent(Intent intent) { String action = intent.getAction(); if (Intent.BOOT_COMPLETED.equals(action)) {

Categories : Android

how to make a jar file auto run after reboot or start of a system
The simplest way is to add java -jar YourJarFile.jar in /etc/rc.d/rc.local Note: Commands in the above file are run at startup (as root). Note that if you do this, your command will NOT respond to the usual service start/ stop commands.

Categories : Java

How to set intellij to show logs in the logs tab and not the output tab
In the application server Run/Debug configuration open the Logs tab and specify the full log file path there. You can just search your disk for algo_js.log file and specify its location.

Categories : Spring

PySide Button Auto Repeat doesn't start until mouse is moved
I was having a similar problem using normal QT4.x on linux. The issue was that something was connected to the clicked signal. I think it was stealing/changing the focus of the mouse. I just changed that item to connect to the the released signal. That doesn't mean you can't connect to clicked, but just be sure that there are no focus stealing side-effects.

Categories : Python

auto generate number of days in another textbox upon selection of start and end date in asp.net c#
I think you are taking the hard way out there is a much easier way of implementing what you are trying to do in ASP.net. First it would require the use of jQuery UI (date-picker). I came up with a pure JavaScript and HTML5 solution to your problem. I think you are going a bit over board with the post back of the data just so you can get the date out of it. Note: I am not doing any validation nor have I made this specific towards your application. Here is my solution: CSS style, just to make things okay looking ;) <!-- link to the jQuery UI CSS --> <link href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" /> <style> #employee_form { width: 350px; background: #f0e68c; padding: .2em; } li { list-style: no

Categories : C#

Get iPhone Logs(not crash logs)
Got a breakthrough!!. We need to re-direct NSLog to a file like this and then access the file. - (void)redirectNSLogToDocumentFolder{ NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *fileName =[NSString stringWithFormat:@"%@.log",[NSDate date]]; NSString *logFilePath = [documentsDirectory stringByAppendingPathComponent:fileName]; freopen([logFilePath cStringUsingEncoding:NSASCIIStringEncoding],"a+",stderr); } http://objcolumnist.com/2009/12/19/redirecting-nslog-to-a-log-file/

Categories : IOS

session has already been started by session.auto-start or session_start() in Zend project
I'm guessing this is on a debian server? If not, this may not be the solution... but we ran into this on our Ubuntu based installations. This is happening because of the combination of the installed PHP package and the cron scripts that are running to take care of the session cleanup. (for whatever reason... not sure why they're doing that...) We were successful by doing the following things: - removing the cron job to clear out the PHP session stuff (trust me, its there - its annoying) - chmod www-data:www-data /var/lib/php5 (or equivalent info) - session.gc_probability = 1 in your php.ini file May not be the best solution, but it took care of it for me.

Categories : PHP

jquery dialog position not working with width:auto - need to auto resize after opening
solved it with the help of this question: jQuery - Dialog auto-resize on dynamic content and maintain center position ajaxStop is called whenever ajax finishes loading, so I'm resizing the dialog when ajaxStop is called and it's works perfectly! $(document).ajaxStop(function(){ $(".dialog").dialog({height:"auto",width:"auto"}); });

Categories : Jquery

C++11 Range-based for-loop efficiency "const auto &i" versus "auto i"
Yes. The same reason if you only ever read an argument you make the parameter const&. T // I'm copying this T& // I'm modifying this const T& // I'm reading this Those are your "defaults". When T is a fundamental type (built-in), though, you generally just revert to const T (no reference) for reading, because a copy is cheaper than aliasing. I have a program that I'm developing in which I'm considering making this change throughout, since efficiency is critical in it Don't make blind sweeping changes. A working program is better than a fast but broken program. How you iterate through your loops probably won't make much of a difference; you're looping for a reason, aren't you? The body of your loop will much more likely be the culprit. If efficiency is

Categories : C++

Auto layout: auto update constraints when some view is empty
Does it need to change when content is visible? If not try this: you could do an update in the viewWillAppear method. For each label, call [firstLabel setNumberOfLines:0]; [firstLabel setText:newProductTitleText]; [firstLabel sizeToFit]; Setting number of lines to 0 lets the label dynamically use an many lines as it needs. If this is an empty label that should actually become 0 lines. This will update the frames and autolayout should take care of the rest.

Categories : IOS

auto zoom and auto center to show all markers in window
From your question, it seems your using multiple markers and you want to set zoom level. If so my suggestion is to take a look at fitBounds(). fitBounds() method adjusts the map's viewport in order to view the passed LatLngBounds in full at the centre of the map. Check out this sample fiddle for demo.

Categories : Javascript

Why can't you use auto as a template type argument (e.g. std::array)?
auto is used to deduce one type from an expression. Using your suggested syntax would not help because exactly one type can be stored in a container. If you need a way to store any type in the container, take a loop at boost::any, so you can use std::array<boost::any, 5> myArray;

Categories : C++

Auto vertical align any auto sized image
This example forces both horizontal and vertical alignment of an image inside a box; in this specific case, constrained to 130x130px. Change the width and height defined as 130px in 2 separate places each in the css to change the constrained size. [edit: added simplified example showing minimum required setup] Simplified example: html: <div class="pic"> <img src="/path/to/pic.jpg"/> </div> css: .pic { display: inline-block; width: 130px; height: 130px; outline: solid 1px #cccce3; font-size: 0; text-align: center; } .pic:before { content: ''; display: inline-block; height: 100%; vertical-align: middle; } .pic img { max-width: 130px; max-height: 130px; display: inline-block; vertical-align: middle; } Compl

Categories : CSS

Online auto complete auto suggest service
If what you are looking for is a service that indexes your raw data into autocomplete then you could make use of hosted ElasticSearch services like qbox.io, searchify.com, Found.no and more You need to index your data first into the elastic search and then query for auto-completion. A detailed explanation on how to achieve that is explained in this rackspace blog and searchify. Excerpt from the rackspace developer blog: Auto-complete (e.g. the slick functionality you see when you begin typing in the search box at the top of your Facebook feed) is an extremely popular feature in applications these days. While a wildcard query in a typical data store like MySQL or MongoDB performs adequately with thousands of records, producing near-instant response times with millions or ev

Categories : Web Services

Auto commit and auto push changes in local repo to git
This sounds like something you'll have to script. If you save as much as I do (a lot), then you'll end up with a lot of commits. Unless you're careful about when you save, you'll probably end up with a messy history, unless you squash things later. Are you sure that you want to commit and push automatically every time you save? It also matters whether or not you're pushing to your own private branch or repo.

Categories : Eclipse

Auto-Hide/Auto-Show Interface
You could do something like this: namespace autohide { public partial class Form1 : Form { public int pin = 0; public Form1() { InitializeComponent(); panel1.Visible = false; } void ChangeIconPin() { switch (pin) { case 0: //Changes the pin-icon to display a unpinned frame. this.button_Pin.BackgroundImage = autohidefixv2.Properties.Resources._55_roto; break; case 1: //Changes the pin-icon to display a pinned frame. this.button_Pin.BackgroundImage = autohidefixv2.Properties.Resources._55_2; break; default:

Categories : C#

Can I have vim auto-format a line, rather than auto-indent it?
You can use gq operator for autoformatting, but I cannot say how good the result will be: this function is used mainly for formatting text: in comments or in HTML/TeX files. Behavior can be adjusted using 'formatexpr' or 'formatprg', you can use the latter if you know good formatter program.

Categories : Vim

Can't start unicorn, master failed to start, check stderr log for details
The socket is the "file" that nginx and unicorn use as a channel for all communication between them. Where have you defined it? In our unicorn configs, we usually have a line like this: listen APP_PATH + "/tmp/pid/.unicorn.sock Then, in your nginx.conf, you need to tell nginx about this socket, e.g.: upstream unicorn { server unix:/var/www/demo/tmp/pid/.unicorn.sock fail_timeout=0; } location / { root /var/www/demo/current/public ; try_files $uri @unicorns; } location @unicorns { proxy_pass http://unicorn; } In this config file, the first section defines how nginx can reach unicorn. The second one actually routes requests to an abstract location "@unicorns" which, in turn, is defined in the last section. This way you can reuse the @unicorns shorthand if your have more compl

Categories : Ruby On Rails

"launchctl start error: Bad file descriptor" when trying to start Neo4j server
I had to remove it from launchd and then it would work, like this: balinjdl-mac:local balinjdl$ neo4j start WARNING! You are using an unsupported version of the Java runtime. Please use Oracle(R) Java(TM) Runtime Environment 7. Using additional JVM arguments: -server -XX:+DisableExplicitGC Dorg.neo4j.server.properties=conf/neo4j-server.properties Djava.util.logging.config.file=conf/logging.properties Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC XX:+CMSClassUnloadingEnabled -Dneo4j.ext.udc.source=homebrew Detected installation in launchd, starting it... launchctl start error: Bad file descriptor balinjdl-mac:local balinjdl$ neo4j remove balinjdl-mac:local balinjdl$ neo4j start WARNING! You are using an unsupported version of the Java runtime. Please use Oracle

Categories : Osx

How to start an Android Activity from an OSGI Bundle start method
I think my topic will provide a response to you, even if not perfect. You may also check FelixDroid which is using a different approach seen on other projects. However, I long for a better solution. Going to see if I can find or write a ContextWrapper that will fill the bill. Full Android support for OSGi bundles (Knopflerfish)

Categories : Android

How to discern between a drag start and a selection start HTML5-Canvas
When working with mouse primitives, there is no way to know if a mouse-down is part of a click, a double-click, or a drag until a subsequent event is fired. A mouse-down followed by a mouse-move is a drag (if the move is greater than some threshold, to allow for human motion while clicking) A mouse-down followed by a mouse-up is a click if the time span is too great to be a double-click. A mouse-down is a double-click if the down/up/down/up falls withing the double-click threshold. The difference between a drag and a rect-select is based (usually) on whether or not an object is present under the mouse position when the down is fired.

Categories : Javascript

Start another batch file with multiple parameters with the start command?
How to read parameters in a batch file: caller batch start "" "%dirofbatch%data1.exe" "%downloc%" "%dirofbatch%" "%lver%" "%lget%" called batch set "parm1=%~1" set "parm2=%~2" set "parm3=%~3" set "parm4=%~4" echo %parm1% %parm2% %parm3% %parm4%

Categories : Batch File

Re-start dependent OSGI bundles on dependency bundle re-start?
You can call refresh and all bundles will be restarted that had package wirings to the old API bundle. You can call refresh on the console or programmatically FrameworkWiring.refreshBundles(...) For more information you can check the javadoc of the mentioned function.

Categories : Java

How can i start a timer like call log duration when activity start?
You can replace your textview by a Chronometer view, set his format using setFormat("HH:MM) and call to start() function when the activity is brought to front. Reference

Categories : Java

How to start Marquee text start from bottom of the screen?
<!DOCTYPE html> <html> <body bgcolor="#2E9AFE"> <marquee style="background-color: #2E9AFE; bottom: 0; color: #ffffff; height: 100%; position: absolute; text-align: center;" scrollamount="2" direction="up" loop="true"> <strong>I AM HERE<br/>Vx.0<br/><br/>DEVELOPER<br/>xxxxxx<br/><br/><br/>CONTACT US<br/>xxxxxx</strong> </marquee> </body> </html> Please note, to my knowledge this is not valid HTML. To validate, check out http://validator.w3.org. Also, there were two body tags (instead of one) and some other HTML that wasn't properly formatted, most of which I tried to address. If you're not yet familiar with CSS, just know that it's your friend. (In other words, you'd probably be

Categories : HTML

Process.Start() with arguments to start Google Chrome
You can use shortcut when call the chrome.exe instead using full path location. Module Module1 Sub Main() System.Diagnostics.Process.Start("chrome.exe", "--incognito") End Sub End Module More: start-google-chrome-from-run-windows-key-r UPDATE I found what is your problem in your code. Your code using –-incognito in the parameter, but it should be --incognito. See the first character in that parameter. Should be - instead –. Module Module1 Sub Main() System.Diagnostics.Process.Start("C:Program Files (x86)GoogleChromeApplicationchrome.exe", "--incognito") End Sub End Module

Categories : Dotnet

Facebook auto like and auto comments for a bot
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles fb_button.Click Dim fb_button As String = Nothing For Each element As HtmlElement In WebBrowser1.Document.All If InStr(element.Id, "u_0_b") Then fb_button = element.Id End If Next WebBrowser1.Document.GetElementById("email").SetAttribute("value", TextBox1.Text) WebBrowser1.Document.GetElementById("pass").SetAttribute("value", TextBox2.Text) WebBrowser1.Document.GetElementById(fb_button).InvokeMember("click") End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load WebBrowser1.Navigate("https://www.facebook.com/") End Sub

Categories : Dotnet

Start an intent to start a specific tab of tab host
In the intent your are sending to TabExercise, you can send the tabindex you want to load, and then call setCurrentTab (int index). Did you try something like this?

Categories : Java



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.