Search Results

Search found 25 results on 1 pages for 'arpit'.

Page 1/1 | 1 

  • gdb : multithreading

    - by Arpit
    Hi Wish to know that I have a program which uses two threads I have put the break point in both the threads. While running the program under gdb I want to switch between the threads and make them run. (thread t1 is active and running and thread t2 hold on the breakpoint I want to stop T1 running and run the T2) Is there any way that I can schedule the threads in gdb. Thanks Arpit

    Read the article

  • How do the Virtual machine network works ?

    - by Arpit
    I wish to know If I am using 2 VM instance on the same setup and I wish to use heavy data flow between the VMs is there any possibility that I get the Timeout (let say I having one timer on the sending end which stops on getting the ack.) I vague question is How network works in VM . I hope I am clear with the question.

    Read the article

  • Website has become slower on a VPS, was much fast on a shared host. What's wrong?

    - by Arpit Tambi
    My shared host suspended my website stating system overload, so I moved my website to a VPS which has 4GB RAM. But for some reason the website has become very slow. This is the vmstat output - procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu------ r b swpd free buff cache si so bi bo in cs us sy id wa st 1 0 0 3050500 0 0 0 0 0 1 0 0 0 0 100 0 0 Here's the Apache Benchmark output for a STATIC html page I ran on the server itself - Benchmarking www.ask-oracle.com (be patient)...apr_poll: The timeout specified has expired (70007) Total of 20 requests completed Update: Server Config: List item Centos 5.6 4 cores cpu 4 GB RAM LAMP stack with APC Wordpress Only one website It takes almost double time to load now, same website was much fast on shared hosting. I know I need to tweak some settings but have no clue where to start from? I have already tried to optimize apache, mysql etc. Update 2: CPU usage is low, see uptime output: 11:09:02 up 7 days, 21:26, 1 user, load average: 0.09, 0.11, 0.09 Update 3: When I load any webpage, browser shows "Waiting" for a long time and then page loads quickly. So I suspect server can accept only limited connections and holds extra connections in a waiting state. How to check this? Update 4: Following is the output on executing netperf TCP STREAM TEST from 0.0.0.0 (0.0.0.0) port 0 AF_INET to localhost.localdomain (127.0.0.1) port 0 AF_INET Recv Send Send Socket Socket Message Elapsed Size Size Size Time Throughput bytes bytes bytes secs. 10^6bits/sec 87380 16384 16384 10.00 9615.40 [root@ip-118-139-177-244 j3ngn5ri6r01t3]# Here are the Apache MPM settings from httpd.conf, do they look okay? <IfModule worker.c> StartServers 5 MaxClients 100 MinSpareThreads 50 MaxSpareThreads 250 ThreadsPerChild 125 MaxRequestsPerChild 10000 ServerLimit 100 </IfModule>

    Read the article

  • install grub on pendrive containing linux installation, making it system independent

    - by arpit
    i have a win7 system and i want to install debian 6 on usb flash drive. the problem is grub loader. i want to install the grub loader on usb itself, so i can just plug in the pendrive in any computer and boot to deb6. so in effect making the flash drive an independent system. i tried it earlier, but ended up with grub loader needing me to insert the pendrive every time to give me boot options to even boot the win7 system, even though it was on primary hdd. so is there a way to turn the pendrive into full linux system with own boot loader, which can automatically detect os in the system i plug it in and be able to boot any of them. totally, self sufficient and system independent; making the pen drive so that it only needs a host system to run the os it carries. thank you, waiting for replies.

    Read the article

  • How do you create a DropShadow on a UIView

    - by Arpit
    My current code doesnt seem to do anything: CGContextRef currentContext = UIGraphicsGetCurrentContext(); CGContextSaveGState(currentContext); float myColorValues[] = {1.0, 0, 0, .8}; CGColorSpaceRef myColorSpace = CGColorSpaceCreateDeviceRGB(); CGColorRef myColor = CGColorCreate(myColorSpace, myColorValues); CGContextSetShadowWithColor (currentContext, CGSizeMake(-1, -1), 0, myColor); //CGContextSetShadow(currentContext, CGSizeMake(-15, 20), 15); [super drawRect: rect]; CGContextRestoreGState(currentContext);

    Read the article

  • Shared Cookies between WebView and HTTPClient?

    - by Arpit
    An Android app I am building requires web authentication for users to make data calls. In Adobe AIR and later the iPhone, we did this by rendering a login page in a webview-equivalent page and setting a cookie when the user signs in. Subsequent data calls use the same Cookie Jar and so are seen as authenticated. In the Android version, I authenticate the user using a WebView and then once thats done, I make a data call using DefaultHttpClient, however I cant seem to load the data on the second call. Is there some cookie gotcha I am missing? I imagine the HTTPClient and WebView would share the same Cookie space. Am I wrong?

    Read the article

  • TreeView Children

    - by Arpit
    I have TreeView as below . Account Payable Address Customer Account Receivable Address Area If I will select Parent nodes then how I can display in ListView of particular child nodes? Also when I click on root node then how I can display only all parent nodes in ListView? Thanks .

    Read the article

  • i want the ruby code of the php code i have given inside , please help me out

    - by Arpit Vaishnav
    <?php // amcharts.com export to image utility // set image type (gif/png/jpeg) $imgtype = 'jpeg'; // set image quality (from 0 to 100, not applicable to gif) $imgquality = 100; // get data from $_POST or $_GET ? $data = &$_POST; // get image dimensions $width = (int) $data['width']; $height = (int) $data['height']; // create image object $img = imagecreatetruecolor($width, $height); // populate image with pixels for ($y = 0; $y < $height; $y++) { // innitialize $x = 0; // get row data $row = explode(',', $data['r'.$y]); // place row pixels $cnt = sizeof($row); for ($r = 0; $r < $cnt; $r++) { // get pixel(s) data $pixel = explode(':', $row[$r]); // get color $pixel[0] = str_pad($pixel[0], 6, '0', STR_PAD_LEFT); $cr = hexdec(substr($pixel[0], 0, 2)); $cg = hexdec(substr($pixel[0], 2, 2)); $cb = hexdec(substr($pixel[0], 4, 2)); // allocate color $color = imagecolorallocate($img, $cr, $cg, $cb); // place repeating pixels $repeat = isset($pixel[1]) ? (int) $pixel[1] : 1; for ($c = 0; $c < $repeat; $c++) { // place pixel imagesetpixel($img, $x, $y, $color); // iterate column $x++; } } } // set proper content type header('Content-type: image/'.$imgtype); header('Content-Disposition: attachment; filename="chart.'.$imgtype.'"'); // stream image $function = 'image'.$imgtype; if ($imgtype == 'gif') { $function($img); } else { $function($img, null, $imgquality); } // destroy imagedestroy($img); ?

    Read the article

  • Treeview Childern

    - by Arpit
    HI I have treeview as below . Account Payable Address Customer Account Receivable Address Area If I will select Parent nodes then how I can display in listview of particular childern nodes .Also when I click on root node then How I can display only all parent nodes in listview . Thanks .

    Read the article

  • How do you send email invites to people who have been invited by users of your website?

    - by Arpit Rai
    We've developed a web application where people can sign-up on our website to make use of our service. We have a functionality that allows users to send invites to their friends by looking up their contacts on Gmail, Yahoo Mail etc. My question is - do we have to use a 3rd party email management software like a MailChimp or SendGrid to send such emails or should we send them directly? If we send the emails directly and if the recipients start marking those emails as spam, isn't there a very high chance that we might get banned by Gmail, Yahoo etc.?

    Read the article

  • Download all image or create zip file of all uploads from the gallary contained uploads

    - by Arpit Vaishnav
    I am on the photo sharing site , and i want to give functionality to download all the images available in the gallery ,, I have taken gallery in a relation where i can get all the iamges by @gallery.uploads , Now what i want is to download this all files , or if its possible to create any zipfile so that we can download that one file containing uploads inside the gallery , thanks

    Read the article

  • Mass-mailing without getting your domain banned

    - by Arpit
    I plan on sending an email to 10k+ email addresses (mostly gmail and yahoo) to announce the launch of my startup's product. I'm planning on using PHPMailer or PHPList to send out the mails. I've never mass-mailed before and had a few basic questions. I've already browsed through some of the other mass-mail threads on this forum but the questions remain hence a new thread. Are newsletters which are sent by so many other organizations sent out in a similar manner - using programs such as PHPMailer or PHPList? When would a GMail or a Yahoo blacklist my domain name - are there any set parameters - 1000 emails in an hour would result in getting banned or some such parameters? If yes, then what sort of settings should I take note of when sending the emails - any format of the email or spread out the 10+ emails over 2 days etc.? If a Gmail or a Yahoo blacklists your domain name - is there any way to get out of the blacklist?

    Read the article

  • please convert this PHP code in ruby

    - by Arpit Vaishnav
    <?php // amcharts.com export to image utility // set image type (gif/png/jpeg) $imgtype = 'jpeg'; // set image quality (from 0 to 100, not applicable to gif) $imgquality = 100; // get data from $_POST or $_GET ? $data = &$_POST; // get image dimensions $width = (int) $data['width']; $height = (int) $data['height']; // create image object $img = imagecreatetruecolor($width, $height); // populate image with pixels for ($y = 0; $y < $height; $y++) { // innitialize $x = 0; // get row data $row = explode(',', $data['r'.$y]); // place row pixels $cnt = sizeof($row); for ($r = 0; $r < $cnt; $r++) { // get pixel(s) data $pixel = explode(':', $row[$r]); // get color $pixel[0] = str_pad($pixel[0], 6, '0', STR_PAD_LEFT); $cr = hexdec(substr($pixel[0], 0, 2)); $cg = hexdec(substr($pixel[0], 2, 2)); $cb = hexdec(substr($pixel[0], 4, 2)); // allocate color $color = imagecolorallocate($img, $cr, $cg, $cb); // place repeating pixels $repeat = isset($pixel[1]) ? (int) $pixel[1] : 1; for ($c = 0; $c < $repeat; $c++) { // place pixel imagesetpixel($img, $x, $y, $color); // iterate column $x++; } } } // set proper content type header('Content-type: image/'.$imgtype); header('Content-Disposition: attachment; filename="chart.'.$imgtype.'"'); // stream image $function = 'image'.$imgtype; if ($imgtype == 'gif') { $function($img); } else { $function($img, null, $imgquality); } // destroy imagedestroy($img); ?

    Read the article

  • wp columns tag clouding with ruby on rails

    - by Arpit Vaishnav
    i am wrking on tag clouds with wp columns ( java script) but it s not wrking .It contains files like tagcloud.swf and swfobject.js . I have added this file in public folder and added html.erb file in the view but its not generating the code and showing any thing on the page the code is <%= javascript_include_tag 'swfobject.js' %> <style type="text/css"> body { background-color: #eee; padding: 20px; } </style> <% tags = (current_user.all_tags) % <% all_tags = tags.flatten.uniq% <script type="text/javascript"> var so = new SWFObject("/tagcloud.swf", "tagcloud", "600", "400", "7", "#ffffff"); // uncomment next line to enable transparency //so.addParam("wmode", "transparent"); so.addVariable("tcolor", "0x333333"); so.addVariable("mode", "tags"); so.addVariable("distr", "true"); so.addVariable("tspeed", "100"); so.addVariable("tagcloud", "<tags> <% for t in all_tags %> <a href='#' style='22' color='0xff0000' hicolor='0x00cc00'><%=t.to_s%></a> <%#= link_to t.to_s ,tag_index_path(t) %> <% end %></tags>"); so.write("flashcontent"); </script></body>

    Read the article

  • embed js code issue from rails application

    - by Arpit Vaishnav
    I am on the ruby on rails application and trying to embed the code for js , added the whole code for embedding in Text box , But when i copy paste in other blogs where embed is poss , i am not getting the full js work , the code is given below <%= text_field_tag "text"," script src=\"/public/javascripts/calendarview.js\" script src=\"/public/javascripts/calendarview_init.js\" link rel=\"stylesheet\" href=\"/public/stylesheets/calendarview.css\" link rel=\"stylesheet\" href=\"/public/stylesheets/calendarview_init.css\" ",:size = 40 % I have just removed < for let it be seen in the coding window PLease help if poss List item

    Read the article

  • Facebook app request in java not working

    - by Arpit Solanki
    I am trying to send a facebook app request to a user through the code below.But it gives an IO Exception and HTTP status code 400 in running.I dont see a any app request being sent to a user on running this. StringBuffer buffer = new StringBuffer(); buffer.append("access_token").append('=').append(this.app_access_token); buffer.append('&').append("message=").append("sent an app request!"); String content = buffer.toString(); try{ URLConnection connection = new URL("https://graph.facebook.com/me/apprequests").openConnection(); connection.setDoOutput(true); connection.setRequestProperty("Content-Type","application/x-www-form-urlencoded"); connection.setRequestProperty("Content-Length",Integer.toString(content.length())); DataOutputStream outs = new DataOutputStream(connection.getOutputStream()); outs.writeBytes(content); outs.flush(); outs.close(); BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream())); String inputLine; while ((inputLine = in.readLine()) != null) { System.out.println(inputLine); } in.close(); } catch(Exception e){ System.out.println(e); }

    Read the article

  • Silverlight Cream for March 08, 2010 -- #809

    - by Dave Campbell
    In this Issue: Michael Washington, Tim Greenfield, Bobby Diaz(-2-), Glenn Block(-2-), Nikhil Kothari, Jianqiang Bao(-2-), and Christopher Bennage. Shoutouts: Adam Kinney announced a Big update for the Project Rosetta site today Arpit Gupta has opened a new blog with a great logo: I think therefore I am dangerous :) From SilverlightCream.com: DotNetNuke Silverlight Traffic Module If it's DNN and Silverlight, it has to be my buddy Michael Washington :) ... Michael has combined those stunning gauges you've seen with website traffic... just too cool!... grab the code and display yours too! Cool demonstration of Silverlight VideoBrush This is a no-code post by Tim Greenfield, but I like the UX on this Jigsaw Puzzle page... and you can make your own. Introducing the Earthquake Locator – A Bing Maps Silverlight Application, part 1 Bobby Diaz has an informative post up on combining earthquake data with BingMaps in Silverlight 3... check it out, the grab the recently posted Live Demo and Source Code Adding Volcanos and Options - Earthquake Locator, part 2 Bobby Diaz also added volcanic activity to his earthquake BinMaps app, and updated the downloadable code and live demo. Building Hello MEF – Part IV – DeploymentCatalog Glenn Block posted a pair of MEF posts yesterday... made me think I missed one :) .. the first one is about the DeploymentCatalog. Note he is going to be using the CodePlex bits in his posts. Building HelloMEF – Part V – Refactoring to ViewModel Glenn Block's part V is about MEF and MVVM -- no, really! ... he is refactoring MVVM into the app with a nod to Josh Smith and Laurent Bugnion... get your head around this... The Case for ViewModel Nikhil Kothari has a post up about the ViewModel, and how it facilitates designer/developer workflow, jumpstarts development, improves scaling, and makes asynch programming development simpler MMORPG programming in Silverlight Tutorial (12)Map Instance (Part I) Jianqiang Bao has part 12 of his MMORPG game up... this one is showing how to deal with obstuctions on maps. MMORPG programming in Silverlight Tutorial (13)Perfect moving mechanism Jianqiang Bao also has part 13 up, and this second one is about sprite movement around the obstructions. 1 Simple Step for Commanding in Silverlight Christopher Bennage blogged about Commanding in Silverlight, he begins with a blog post about commands in Silverlight 4 then goes on to demonstrate the Caliburn way of doing commanding. Stay in the 'Light! Twitter SilverlightNews | Twitter WynApse | WynApse.com | Tagged Posts | SilverlightCream Join me @ SilverlightCream | Phoenix Silverlight User Group Technorati Tags: Silverlight    Silverlight 3    Silverlight 4    MIX10

    Read the article

  • SCHA API for resource group failover / switchover history

    - by krishna.k.murthy
    The Oracle Solaris Cluster framework keeps an internal log of cluster events, including switchover and failover of resource groups. These logs can be useful to Oracle support engineers for diagnosing cluster behavior. However, till now, there was no external interface to access the event history. Oracle Solaris Cluster 4.2 provides a new API option for viewing the recent history of resource group switchovers in a program-parsable format. Oracle Solaris Cluster 4.2 provides a new option tag argument RG_FAILOVER_LOG for the existing API command scha_cluster_get which can be used to list recent failover / switchover events for resource groups. The command usage is as shown below: # scha_cluster_get -O RG_FAILOVER_LOG number_of_days number_of_days : the number of days to be considered for scanning the historical logs. The command returns a list of events in the following format. Each field is separated by a semi-colon [;]: resource_group_name;source_nodes;target_nodes;time_stamp source_nodes: node_names from which resource group is failed over or was switched manually. target_nodes: node_names to which the resource group failed over or was switched manually. There is a corresponding enhancement in the C API function scha_cluster_get() which uses the SCHA_RG_FAILOVER_LOG query tag. In the example below geo-infrastructure (failover resource group), geo-clusterstate (scalable resource group), oracle-rg (failover resource group), asm-dg-rg (scalable resource group) and asm-inst-rg (scalable resource group) are part of Geographic Edition setup. # /usr/cluster/bin/scha_cluster_get -O RG_FAILOVER_LOG 3 geo-infrastructure;schost1c;;Mon Jul 21 15:51:51 2014 geo-clusterstate;schost2c,schost1c;schost2c;Mon Jul 21 15:52:26 2014 oracle-rg;schost1c;;Mon Jul 21 15:54:31 2014 asm-dg-rg;schost2c,schost1c;schost2c;Mon Jul 21 15:54:58 2014 asm-inst-rg;schost2c,schost1c;schost2c;Mon Jul 21 15:56:11 2014 oracle-rg;;schost2c;Mon Jul 21 15:58:51 2014 geo-infrastructure;;schost2c;Mon Jul 21 15:59:19 2014 geo-clusterstate;schost2c;schost2c,schost1c;Mon Jul 21 16:01:51 2014 asm-inst-rg;schost2c;schost2c,schost1c;Mon Jul 21 16:01:10 2014 asm-dg-rg;schost2c;schost2c,schost1c;Mon Jul 21 16:02:10 2014 oracle-rg;schost2c;;Tue Jul 22 16:58:02 2014 oracle-rg;;schost1c;Tue Jul 22 16:59:05 2014 oracle-rg;schost1c;schost1c;Tue Jul 22 17:05:33 2014 Note that in the output some of the entries might have an empty string in the source_nodes. Such entries correspond to events in which the resource group is switched online manually or during a cluster boot-up. Similarly, an empty destination_nodes list indicates an event in which the resource group went offline. - Arpit Gupta, Harish Mallya

    Read the article

1