Daily Archives

Articles indexed Wednesday November 7 2012

Page 4/17 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • C++ - Creating folder method

    - by Matthew
    I have the following method in C++: void create_folder(LPCWSTR full_folder) //Method to create folder in case it does not exist { if(!CreateDirectory(full_folder,attr)) //Checking whether the folder already exists { switch (GetLastError()) { case ERROR_ALREADY_EXISTS: printf("The folder already exists!\n\n"); break; case NULL: printf("The folder does not exist!\n\n"); printf("The folder was created successfully!\n\n"); break; } } } In case the folder already exists, the correct message is displayed on the screen. However, if the folder does NOT exist, nothing is displayed on the screen, that is, the part identified by case NULL is not executed. How can I solve this problem? In other words, how can I get the code after the case NULL to run if the folder does not exist?

    Read the article

  • C#: HTTPWebResponse using application/x-www-form-urlencoded

    - by CSharpened
    So I sent an HTTPWebRequest using application/x-www-form-urlencoded as my content type. I assume that this means the reponse will be returned in a similar type? (EDIT: Have now been told this isn't the case) My question is this. How do I access the different key/value pairs returned in the response. My code so far looks like this. I can of course read the string but surely there is a better way to access the data other than ripping the string apart. HttpWebResponse response = SendPOSTRequest("https://site/page?Service=foo", content.ToString(), "", "", true); string responseCode = response.StatusCode.ToString(); string responseStatusDescription = response.StatusDescription; StreamReader sr = new StreamReader(response.GetResponseStream()); string result = sr.ReadToEnd(); I tried using XML/linq to read the elements into an XDocument but of course it is not being returned in XML form. Assume I have 3 or 4 different pieces of information in there how could I read them out? EDIT: I have just checked and the data is being returned as text/plain. How can this be processed easily? EDIT: The response string once retrieved via a streamreader is: VPSProtocol=2.23 Status=OK StatusDetail=Server transaction registered successfully. VPSTxId={FDC93F3D-FC64-400D-875F-0B7E855AD81F} SecurityKey=***** NextURL=https://foo.com/PaymentPage.asp?TransactionID={875F-0B7E855AD81F}

    Read the article

  • Scapy PcapReader and packets time

    - by auino
    I'm reading a PCAP file using Scapy using a script such as the (semplified) following one: #! /usr/bin/env python from scapy.all import * # ... myreader = PcapReader(myinputfile) for p in myreader: pkt = p.payload print pkt.time In this case the packets time is not relative to PCAP capture time, but starts from the instant I've launched my script. I'd like to start from 0.0 or to be relative to the PCAP capture. How can I fix it (possibly without "manually" retrieving the first packet time and repeatedly using math to fix the problem)?

    Read the article

  • Launch configuration for an Eclipse RCP project

    - by ekebsi
    I am new to Eclipse and have been asked to make some changes to an RCP project. Now I can not get it to run. Unfortunately I cannot contact the author to get some help. I would appreciate an hint which could lead to the solution. When I lunch the application I get following log message: !ENTRY org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE One or more bundles are not resolved because the following root constraints are not resolved: !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.team.core.nl1_3.3.0.I20070607.jar was not resolved. !SUBENTRY 2 org.eclipse.team.core.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.team.core_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.emf.edit.ui.nl1_2.3.0.v200706262000.jar was not resolved. !SUBENTRY 2 org.eclipse.emf.edit.ui.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.emf.edit.ui_[2.0.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.team.ui.nl1_3.3.0.I20070607.jar was not resolved. !SUBENTRY 2 org.eclipse.team.ui.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.team.ui_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.rcp.nl1_3.2.0.v20070612.jar was not resolved. !SUBENTRY 2 org.eclipse.rcp.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.rcp_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.ui.win32.nl1_3.2.100.I20070319-0010.jar was not resolved. !SUBENTRY 2 org.eclipse.ui.win32.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.ui.win32_[3.2.0,4.0.0). !ENTRY org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists: !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.emf.edit.ui.nl1_2.3.0.v200706262000.jar [29] was not resolved. !SUBENTRY 2 org.eclipse.emf.edit.ui.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.emf.edit.ui_[2.0.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.team.ui.nl1_3.3.0.I20070607.jar [45] was not resolved. !SUBENTRY 2 org.eclipse.team.ui.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.team.ui_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.ui.win32.nl1_3.2.100.I20070319-0010.jar [66] was not resolved. !SUBENTRY 2 org.eclipse.ui.win32.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.ui.win32_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.team.core.nl1_3.3.0.I20070607.jar [83] was not resolved. !SUBENTRY 2 org.eclipse.team.core.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.team.core_[3.2.0,4.0.0). !SUBENTRY 1 org.eclipse.osgi 2 0 2012-11-07 09:03:45.878 !MESSAGE Bundle update@plugins/org.eclipse.rcp.nl1_3.2.0.v20070612.jar [124] was not resolved. !SUBENTRY 2 org.eclipse.rcp.nl1 2 0 2012-11-07 09:03:45.878 !MESSAGE Missing host org.eclipse.rcp_[3.2.0,4.0.0). I am using a windows 7 Enterprise 64 (4GB) and Eclipse Juno 64.

    Read the article

  • How to avoid overflow in expr. A * B - C * D

    - by Ir0nm
    I need to compute an expression which looks like: A*B - C*D, where their types are: signed long long int A, B, C, D; Each number can be really big (not overflowing its type). While A*B could cause overflow, at same time expression A*B - C*D can be really small. How can I compute it correctly? For example: MAX * MAX - (MAX - 1) * (MAX + 1) == 1, where MAX = LLONG_MAX - n and n - some natural number.

    Read the article

  • PHP-SDK too many redirects

    - by Roel Veldhuizen
    I'm using the PHP-SDK for Facebook and got the example to work on my localhost. However, when building a script on a server the script stays quite busy with redirecting from my script to facebook and back. (Error: Fout 310 (net::ERR_TOO_MANY_REDIRECTS):) It seems that many more people have got this issue (here, here, here, here). Though, I can't find a clear answer what goes wrong. Redirect to facebook (response 302): https://www.facebook.com/dialog/oauth?client_id=166958180001271&redirect_uri=http%3A%2F%2Fdomain.com%2Fscripts%2FGateway.php%3Faction%3DAllowFacebookAccessAction%26app%3D14&state=0dbc178a375595da4751265a7147c01e#_=_ Redirect to mydomain (response 302): http://domain.com/scripts/Gateway.php?action=AllowFacebookAccessAction&app=14&state=0dbc178a375595da4751265a7147c01e&code=AQD-dTeyns0OWpGb_PzfHxUy2iRmpc1XgP6Q24DDRX8MiRTE10lV-b-aSNIlOLVHk576vRs3H8Pf9n0kGwU827MrkzUCUoQGFGEQBkkOJnCy9zb6hZs7TVBsKL2iSuZIhDjLsCOPeKy3zfb37Q6LGhtMICCdB_IQAvU0uRvAkSAX8tdVJ65PEv8imx-2yvLaMoGJleZwKogh7m03vlhV8hJk#_=_ Part of the code that creates this issue ... $facebook = new FacebookApi(array( 'appId' => $app->getProperty('apiKey'), 'secret' => $app->getProperty('secretKey'), )); $user = $facebook->getUser(); if (!$user) { header('location: ' . $facebook->getLoginUrl()); exit; } ... UPDATE: I ruled out that its a server setting. I was able to run the original example script on that server.

    Read the article

  • Substring text with html tags in javascript

    - by honzahommer
    Do you have solution to substring text with html tags in Javascipt? For example: var str = 'Lorem ipsum <a href="#">dolor <strong>sit</strong> amet</a>, consectetur adipiscing elit.' html_substr(str, 20) // return Lorem ipsum <a href="#">dolor <strong>si</strong></a> html_substr(str, 30) // return Lorem ipsum <a href="#">dolor <strong>sit</strong> amet</a>, co

    Read the article

  • Address family not supported by protocol exception

    - by srg
    I'm trying to send a couple of values from an android application to a web service which I've setup. I'm using Http Post to send them but when I run the application I get the error- request time failed java.net.SocketException: Address family not supported by protocol. I get this while debugging with both the emulator as well as a device connected by wifi. I've already added the internet permission using: <uses-permission android:name="android.permission.INTERNET" /> This is the code i'm using to send the values void insertData(String name, String number) throws Exception { String url = "http://192.168.0.12:8000/testapp/default/call/run/insertdbdata/"; HttpClient client = new DefaultHttpClient(); HttpPost post = new HttpPost(url); try { List<NameValuePair> params = new ArrayList<NameValuePair>(2); params.add(new BasicNameValuePair("a", name)); params.add(new BasicNameValuePair("b", number)); post.setEntity(new UrlEncodedFormEntity(params)); HttpResponse response = client.execute(post); }catch(Exception e){ e.printStackTrace(); } Also I know that my web service work fine because when I send the values from an html page it works fine - <form name="form1" action="http://192.168.0.12:8000/testapp/default/call/run/insertdbdata/" method="post"> <input type="text" name="a"/> <input type="text" name="b"/> <input type="submit"/> I've seen questions of similar problems but haven't really found a solution. Thanks

    Read the article

  • Picking only the value field out of Cloudwatch Dimensions, Java

    - by GroovyUser
    I have some data that are retried from the cloudwatch api's. Specifically I have used listMetrics. The data that I got from this call is : {Metrics: [{Namespace: Metric from grails, MetricName: hello123, Dimensions: [{Name: name, Value: 1425, }], }, {Namespace: Metric from grails, MetricName: hello123, Dimensions: [{Name: name, Value: 1068, }], }, That was the correct data as I would expect. I need a way to return only the value fields. Not others things. Is there any way to do this, in java? Thanks in advance.

    Read the article

  • OpenVPN useradd error

    - by zfz
    I tried to install an OpenVPN access server in Centos 6 on a linode VPS. The installation is okay for my ubuntu 11.10 distro in another VPS. The installation error occours when adding the user "openvpn" in Centos. The error message is "useradd: canot open /etc/passwd" The detail of My "/etc/passwd" file: "-rw-r--r-- 1 root root 1194 Oct 9 00:33 /etc/passwd" I am not quite familiar with Centos, so how can I add the user "openvpn" in order to setup the VPN service? Thanks.

    Read the article

  • Server Vs Service / Physical Vs Virtual

    - by user559142
    When reading definitions for a server service (e.g. iis) you will often find that there are several cross references to a virtual server but none seem to definitively refer to the two as the same..... Can somebody help me to understand the differences - I cannot get my head around what the difference between each is? Ideally I would like to know the differences between the following/or indeed if any refer to the same... 1) Logical Server 2) Virtual Host 3) Logical Partition 4) Physical Server Vs Virtual Server 5) Server Service Vs Virtual Host

    Read the article

  • Apache mod_wsgi elegant clustering method

    - by Dr I
    I'm currently trying to build a scalable infrastructure for my Python webservers. Actually, I'm trying to find the most elegant way to build a scalable cluster to host all my Python WebServices. For now, I'm using three servers like this: 1 x PuppetMaster to deploy my servers. 2 x Apache Reverse Proxy Front-end servers. 1 x Apache HTTPd Server which host the Python WSGI Applications and binded to using mod_wsgi. 4 x MongoDB Clustered server. Everything is OK concerning the Reverse proxy and the DB Backend, I'm able to easily add a new Reverse Proxy and a new DB Node, but my problem is about the Python WebServer. I thinked to just provision a new node with exactly the same configuration and a rsync replication between the two nodes, but It's not really usefull in term of deployement for my developpers etc. So if you have a solution which is as efficient and elegant that the Tomcat Cluster I'll be really happy to ear it ;-)

    Read the article

  • initctl respawn does not reload configuration

    - by DELUXEnized
    My upstart service is running with the respawn option. I was hoping that if I deploy a new service config, the config will be loaded, when the service respawns. Neither the initctl reload-configuration command forces a reload, nor the restart command. Only an explicit stop and start reloads the configuration. The problem is, that I can not stop and start the service, at deploy time. The service itself schedules its restart by just shutting down. Is this behavior by design or am I missing something? Would it change anything, if I did the respawn with a second watchdog-service by an explicit start if my service stops? Why is there a difference between an explicit start/stop and the restart command or respawn option. Thanks.

    Read the article

  • UDISKS instead of HAL

    - by MeJ
    Does anybody have some expirence with udisks, because HAL won't be longer supported on the most linux distribution, so I am thinking of to use udisks for UDI in $(hal-find-by-property --key storage.bus --string usb) do HAL_TMP=`hal-get-property --udi $UDI --key storage.removable.media_available` if [ "$HAL_TMP" = "true" ]; then HAL_DEV=$(hal-get-property --udi $UDI --key block.device) HAL_SIZE=$(hal-get-property --udi $UDI --key storage.removable.media_size) HAL_TYPE=$(hal-get-property --udi $UDI --key storage.drive_type) How do I have to adapt the above mentioned commands but use udisks instead of hal Thanks!

    Read the article

  • iptables - drop all HTTP(S) traffic but from CloudFlare

    - by Martin
    I would like to allow only HTTP(S) traffic coming from CloudFlare. In that way attackers cannot attack the server directly. I know CloudFlare is not mainly a DDoS mitigator, but I would like to try it either way. I'm currently only having access to iptables (ipv4 only), but will try to install ip6tables soon. I just need to have this fixed soon. (we're getting (D)DoSed atm.) I was thinking about something like this: iptables -I INPUT -s <CloudFlare IP> --dport 80 -j ACCEPT iptables -I INPUT -s <CloudFlare IP> --dport 443 -j ACCEPT iptables -I INPUT -p tcp --dport 80 -j DROP iptables -I INPUT -p tcp --dport 443 -j DROP I know that CloudFlare has multiple IPs, but just for an example. Would this be the right way?

    Read the article

  • Oracle HTTP Server access_log - GET /error/404.html HTTP/1.0 200 7001 entries

    - by Pavan
    access_log shows the following entries repeatedly, seems like it is polling some thing. There were so many entries keep on adding to the log, making it difficult to debug for actual error message. aaa.bbb.ccc.ddd - - [07/Nov/2012:00:02:48 -0800] "HEAD /index.html HTTP/1.1" 200 - abc.bcd.cda.dab - - [07/Nov/2012:00:02:50 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dac - - [07/Nov/2012:00:02:51 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dab - - [07/Nov/2012:00:02:56 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dac - - [07/Nov/2012:00:02:56 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dab - - [07/Nov/2012:00:03:01 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dac - - [07/Nov/2012:00:03:01 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dab - - [07/Nov/2012:00:03:06 -0800] "GET /error/404.html HTTP/1.0" 200 7001 abc.bcd.cda.dac - - [07/Nov/2012:00:03:06 -0800] "GET /error/404.html HTTP/1.0" 200 7001 aaa.bbb.ccc.ddd - - [07/Nov/2012:00:03:08 -0800] "HEAD /index.html HTTP/1.1" 200 - how to avoid these repeating entries?

    Read the article

  • Block IPs if they access a resource

    - by Victor Oliva
    I own a server that it's costantly being attacked by scripts (that try to access to phpMyAdmin's setup file's and stuff like this). I've heard that many people get this kinds of attacks, but I'm starting to worry since they are getting more common (last month I got 2 attacks, and on november 7th there are 3 attempts already (1st, 4th and 6th of nov). I'm not really concerned about it, since I don't have any database. All the info i have on that server is absolutely public, but I'm worried about that attacking-rate increase. So I thought I could -temporarily- block the IPs that come from those attackers, or something that could make my server ignore requests that ask for phpMyAdmin, pma, xamp, etc. Is there something like that? my server is Linux+Apache+Php

    Read the article

  • Automatic Reply Out of Hours

    - by Inbr3d
    Is there a way i can use a rule or "timer" of some sort to turn on out of office, or enable an auto reply for 1 mailbox (Sales mailbox) within a time period. Reason: We deal with all timezones, we only open 6am-8pm. critical sales are sometimes lost the automatic reply will involve a telephone number for emergency sales. (yes, spam i know) I wish the auto reply to come from "[email protected]" if this is possible. I've lokekd at transport rules, cant see anything. I cant word my question well enough for google to give an answer.

    Read the article

  • apache httpd cannot browse through browser

    - by nuttynibbles
    i've setup apache and php on a virtual machine. everything works fine in the virtual machine. im able to execute php files and run up phpmyadmin connecting to mysql. on my host machine, im able ping and ssh into the remote machines. however, im unable to browse the php files on the host browser using the ip address. in my httpd.conf, im listening to port 80. i enabled the ServerName 192.168.75.102:80 am i missing some settings? port settings maybe?

    Read the article

  • e2fsck extremely slow, although enough memory exists

    - by kaefert
    I've got this external USB-Disk: kaefert@blechmobil:~$ lsusb -s 2:3 Bus 002 Device 003: ID 0bc2:3320 Seagate RSS LLC As can be seen in this dmesg output, there is some problem that prevents that disk from beeing mounted: kaefert@blechmobil:~$ dmesg ... [ 113.084079] usb 2-1: new high-speed USB device number 3 using ehci_hcd [ 113.217783] usb 2-1: New USB device found, idVendor=0bc2, idProduct=3320 [ 113.217787] usb 2-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1 [ 113.217790] usb 2-1: Product: Expansion Desk [ 113.217792] usb 2-1: Manufacturer: Seagate [ 113.217794] usb 2-1: SerialNumber: NA4J4N6K [ 113.435404] usbcore: registered new interface driver uas [ 113.455315] Initializing USB Mass Storage driver... [ 113.468051] scsi5 : usb-storage 2-1:1.0 [ 113.468180] usbcore: registered new interface driver usb-storage [ 113.468182] USB Mass Storage support registered. [ 114.473105] scsi 5:0:0:0: Direct-Access Seagate Expansion Desk 070B PQ: 0 ANSI: 6 [ 114.474342] sd 5:0:0:0: [sdb] 732566645 4096-byte logical blocks: (3.00 TB/2.72 TiB) [ 114.475089] sd 5:0:0:0: [sdb] Write Protect is off [ 114.475092] sd 5:0:0:0: [sdb] Mode Sense: 43 00 00 00 [ 114.475959] sd 5:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA [ 114.477093] sd 5:0:0:0: [sdb] 732566645 4096-byte logical blocks: (3.00 TB/2.72 TiB) [ 114.501649] sdb: sdb1 [ 114.502717] sd 5:0:0:0: [sdb] 732566645 4096-byte logical blocks: (3.00 TB/2.72 TiB) [ 114.504354] sd 5:0:0:0: [sdb] Attached SCSI disk [ 116.804408] EXT4-fs (sdb1): ext4_check_descriptors: Checksum for group 3976 failed (47397!=61519) [ 116.804413] EXT4-fs (sdb1): group descriptors corrupted! ... So I went and fired up my favorite partition manager - gparted, and told it to verify and repair the partition sdb1. This made gparted call e2fsck (version 1.42.4 (12-Jun-2012)) e2fsck -f -y -v /dev/sdb1 Although gparted called e2fsck with the "-v" option, sadly it doesn't show me the output of my e2fsck process (bugreport https://bugzilla.gnome.org/show_bug.cgi?id=467925 ) I started this whole thing on Sunday (2012-11-04_2200) evening, so about 48 hours ago, this is what htop says about it now (2012-11-06-1900): PID USER PRI NI VIRT RES SHR S CPU% MEM% TIME+ Command 3704 root 39 19 1560M 1166M 768 R 98.0 19.5 42h56:43 e2fsck -f -y -v /dev/sdb1 Now I found a few posts on the internet that discuss e2fsck running slow, for example: http://gparted-forum.surf4.info/viewtopic.php?id=13613 where they write that its a good idea to see if the disk is just that slow because maybe its damaged, and I think these outputs tell me that this is not the case in my case: kaefert@blechmobil:~$ sudo hdparm -tT /dev/sdb /dev/sdb: Timing cached reads: 3562 MB in 2.00 seconds = 1783.29 MB/sec Timing buffered disk reads: 82 MB in 3.01 seconds = 27.26 MB/sec kaefert@blechmobil:~$ sudo hdparm /dev/sdb /dev/sdb: multcount = 0 (off) readonly = 0 (off) readahead = 256 (on) geometry = 364801/255/63, sectors = 5860533160, start = 0 However, although I can read quickly from that disk, this disk speed doesn't seem to be used by e2fsck, considering tools like gkrellm or iotop or this: kaefert@blechmobil:~$ iostat -x Linux 3.2.0-2-amd64 (blechmobil) 2012-11-06 _x86_64_ (2 CPU) avg-cpu: %user %nice %system %iowait %steal %idle 14,24 47,81 14,63 0,95 0,00 22,37 Device: rrqm/s wrqm/s r/s w/s rkB/s wkB/s avgrq-sz avgqu-sz await r_await w_await svctm %util sda 0,59 8,29 2,42 5,14 43,17 160,17 53,75 0,30 39,80 8,72 54,42 3,95 2,99 sdb 137,54 5,48 9,23 0,20 587,07 22,73 129,35 0,07 7,70 7,51 16,18 2,17 2,04 Now I researched a little bit on how to find out what e2fsck is doing with all that processor time, and I found the tool strace, which gives me this: kaefert@blechmobil:~$ sudo strace -p3704 lseek(4, 41026998272, SEEK_SET) = 41026998272 write(4, "\212\354K[_\361\3nl\212\245\352\255jR\303\354\312Yv\334p\253r\217\265\3567\325\257\3766"..., 4096) = 4096 lseek(4, 48404766720, SEEK_SET) = 48404766720 read(4, "\7t\260\366\346\337\304\210\33\267j\35\377'\31f\372\252\ffU\317.y\211\360\36\240c\30`\34"..., 4096) = 4096 lseek(4, 41027002368, SEEK_SET) = 41027002368 write(4, "\232]7Ws\321\352\t\1@[+5\263\334\276{\343zZx\352\21\316`1\271[\202\350R`"..., 4096) = 4096 lseek(4, 48404770816, SEEK_SET) = 48404770816 read(4, "\17\362r\230\327\25\346//\210H\v\311\3237\323K\304\306\361a\223\311\324\272?\213\tq \370\24"..., 4096) = 4096 lseek(4, 41027006464, SEEK_SET) = 41027006464 write(4, "\367yy>x\216?=\324Z\305\351\376&\25\244\210\271\22\306}\276\237\370(\214\205G\262\360\257#"..., 4096) = 4096 lseek(4, 48404774912, SEEK_SET) = 48404774912 read(4, "\365\25\0\21|T\0\21}3t_\272\373\222k\r\177\303\1\201\261\221$\261B\232\3142\21U\316"..., 4096) = 4096 ^CProcess 3704 detached around 16 of these lines every second, so 4 read and 4 write operations every second, which I don't consider to be a lot.. And finally, my question: Will this process ever finish? If those numbers from fseek (48404774912) represent bytes, that would be something like 45 gigabytes, with this beeing a 3 terrabyte disk, which would give me 134 days to go, if the speed stays constant, and e2fsck scans the disk like this completly and only once. Do you have some advice for me? I have most of the data on that disk elsewhere, but I've put a lot of hours into sorting and merging it to this disk, so I would prefer to getting this disk up and running again, without formatting it anew. I don't think that the hardware is damaged since the disk is only a few months and since I can't see any I/O errors in the dmesg output. UPDATE: I just looked at the strace output again (2012-11-06_2300), now it looks like this: lseek(4, 1419860611072, SEEK_SET) = 1419860611072 read(4, "3#\f\2447\335\0\22A\355\374\276j\204'\207|\217V|\23\245[\7VP\251\242\276\207\317:"..., 4096) = 4096 lseek(4, 43018145792, SEEK_SET) = 43018145792 write(4, "]\206\231\342Y\204-2I\362\242\344\6R\205\361\324\177\265\317C\334V\324\260\334\275t=\10F."..., 4096) = 4096 lseek(4, 1419860615168, SEEK_SET) = 1419860615168 read(4, "\262\305\314Y\367\37x\326\245\226\226\320N\333$s\34\204\311\222\7\315\236\336\300TK\337\264\236\211n"..., 4096) = 4096 lseek(4, 43018149888, SEEK_SET) = 43018149888 write(4, "\271\224m\311\224\25!I\376\16;\377\0\223H\25Yd\201Y\342\r\203\271\24eG<\202{\373V"..., 4096) = 4096 lseek(4, 1419860619264, SEEK_SET) = 1419860619264 read(4, ";d\360\177\n\346\253\210\222|\250\352T\335M\33\260\320\261\7g\222P\344H?t\240\20\2548\310"..., 4096) = 4096 lseek(4, 43018153984, SEEK_SET) = 43018153984 write(4, "\360\252j\317\310\251G\227\335{\214`\341\267\31Y\202\360\v\374\307oq\3063\217Z\223\313\36D\211"..., 4096) = 4096 So the numbers in the lseek lines before the reads, like 1419860619264 are already a lot bigger, standing for 1.29 terabytes if those numbers are bytes, so it doesn't seem to be a linear progress on a big scale, maybe there are only some areas that need work, that have big gaps in between them. UPDATE2: Okey, big disappointment, the numbers are back to very small again (2012-11-07_0720) lseek(4, 52174548992, SEEK_SET) = 52174548992 read(4, "\374\312\22\\\325\215\213\23\0357U\222\246\370v^f(\312|f\212\362\343\375\373\342\4\204mU6"..., 4096) = 4096 lseek(4, 46603526144, SEEK_SET) = 46603526144 write(4, "\370\261\223\227\23?\4\4\217\264\320_Am\246CQ\313^\203U\253\274\204\277\2564n\227\177\267\343"..., 4096) = 4096 so either e2fsck goes over the data multiple times, or it just hops back and forth multiple times. Or my assumption that those numbers are bytes is wrong. UPDATE3: Since it's mentioned here http://forums.fedoraforum.org/showthread.php?t=282125&page=2 that you can testisk while e2fsck is running, i tried that, though not with a lot of success. When asking testdisk to display the data of my partition, this is what I get: TestDisk 6.13, Data Recovery Utility, November 2011 Christophe GRENIER <[email protected]> http://www.cgsecurity.org 1 P Linux 0 4 5 45600 40 8 732566272 Can't open filesystem. Filesystem seems damaged. And this is what strace currently gives me (2012-11-07_1030) lseek(4, 212460343296, SEEK_SET) = 212460343296 read(4, "\315Mb\265v\377Gn \24\f\205EHh\2349~\330\273\203\3375\206\10\r3=W\210\372\352"..., 4096) = 4096 lseek(4, 47347830784, SEEK_SET) = 47347830784 write(4, "]\204\223\300I\357\4\26\33+\243\312G\230\250\371*m2U\t_\215\265J \252\342Pm\360D"..., 4096) = 4096 (times are in CET)

    Read the article

  • How do I send email with sendmail to external hosts?

    - by Jake
    If I wanted to send an email to a user on the same linux machine, I can run: echo -e "Subject: Foo\n\nBar\n" | sendmail -v jacob But if I run: echo -e "Subject: Foo\n\nBar\n" | sendmail -v [email protected] It will give me the error: 050 >>> MAIL From:<jacob@mu> SIZE=321 050 550 5.1.8 Cannot resolve your domain {mx-us011} If my machine has access to the internet but is behind a router and has no domain associated with it, can I use sendmail to send mail to this address? Do I need to connect through an SMTP server? Can I do that with sendmail? If I use sendmail's -f option and put my gmail account there it will work. Can (or should I) I use my IP address? echo -e "Subject: Foo\n\nBar\n" | sendmail -v -f [email protected] [email protected] I'm a bit lost on how all this comes together in sending mail from the command line.

    Read the article

  • Having troubles connectiong Magento to external Windows Database Server using Windows Azure

    - by Kevin H
    "I tried to make this easy to read through" I am using Ubuntu 12.04 LTS for Magento and installed these commands onto the system: sudo apt-get install apache2 sudo apt-get install php5 libapache2-mod-php5 sudo apt-get install php5-mysql sudo apt-get install php5-curl php5-mcrypt php5-gd php5-common sudo apt-get install php5-gd I used Windows Server 2008 R2 August 2012 for Mysql Server For a reference, I used http://www.windowsazure.com/en-us/manage/windows/common-tasks/install-mysql/ When the server was setup, I added an empty disk to it Then, I added endpoints 3306 Next I accessed the server remotely After that, I formatted the empty disk and was inserted as F: Next I downloaded Mysql from http://*.mysql.com version Windows (x86, 64-bit), MSI Installer 5.5.28 In the installation process, I used these settings: Typical Setup - Clicked Next, install, next Chose Detailed Configuration - Clicked next Chose Dedicated MySQL Server Machine - Clicked Next Chose Transactional Database Only - Clicked Next Chose the "F:" Drive - Clicked Next Chose Online Transactional Processing (OLTP) - Clicked Next For Networking Options, I checkmarked 'Enable TCP/IP Networking" 'Add firewall exception for this port' 'Enable Strict Mode' - Clicked Next Chose Standard Character Set - Clicked Next For Windows Options, I checkedmarked 'Install as Window Service" 'Launch the MySQL Server automatically' 'Include Bin Directory in Windows PATH - Clicked Next For Security Options, I checkmarked 'Modify Security Settings' and set root password - Clicked Next Finally clicked Execute and Finish These are the Firewall Setting that I set I clicked inbound rules Properties Scope Allow IP Address and used the internal Address for Magento Server Clicked Apply and exited Next, I opened up MySQL 5.x Command Line Client Entered Root Password Then entered these commands mysql create database magento; mysql Create user magentouser identified by 'password'; mysql Grant select, insert, create, alter, update, delete, lock tables on magento.* to magentouser mysql exit Finally, I opened up the Magento Downloader Magento validation has approved all PHP version is right. Your version is 5.3.10-1ubuntu3.4. PHP Extension curl is loaded PHP Extension dom is loaded PHP Extension gd is loaded PHP Extension hash is loaded PHP Extension iconv is loaded PHP Extension mcrypt is loaded PHP Extension pcre is loaded PHP Extension pdo is loaded PHP Extension pdo_mysql is loaded PHP Extension simplexml is loaded These are all installed on Magento Server For the Database Connection, I used: The Database server only has MySQL 5.5 Server installed on it Host - Internal IP address User Name - The User I created when setting up database Password - The Password I created when setting up database For the password, I did some research and found out that Magento only accepts alphanumeric, so I went and set it up again and used only alphanumeric for the User password Now, I am still getting Accessed denied for database Connection. Also, I have tryed to setup mysql on independant Linux Server but kept getting errors. When, I found the solution. Wouldn't work, so I decided to try Windows. These is the questions, I have been asking and researching to debug this issue Is it because I am using Linux for magento and Windows for Database. I have had no luck in finding a reason why this wouldn't work There must be something, I am missing I also researched the difference between linux sql databases and windows sql databases but have not come to conclusion, if installing Mysql on windows would make a difference in syntax and coding. I have spent a lot of time looking into this and need some help with direction on how to complete my project. Any type of help would be appreciated.

    Read the article

  • Can we send Web mail to other(different ) domain using common name?

    - by Mythli
    I have two different internal domains , where i need to send mail from one domain to another domain using Common Name. conditions: It is from Web, Not from Notes Client. Reason why I'm using common name is We configured and used the common names for all the employees which we don't want to change For this Can we do anything on server configuration? I can see different setting in admin client but sure where or what will fix From Admin Client-server- Configuration setting -Router/SMTP - Address lookup : Fullname Only Above will do anything for my issue?

    Read the article

  • With the Supermicro Embeded BMC, is it possible to connect to Serial Over Lan via SSH?

    - by Stefan Lasiewski
    I have several dozen Supermicro servers which use the Supermicro Embedded BMC. The documentation on that page suggests that I can access the Serial Over LAN (Serial Console) over SSH: SMASH and CLP support SSH based SOL Power control of the server But when I ssh into my BMC, all I see is a Busybox implementation, with no clear ability to connect to the SOL: # ssh 192.168.100.100 -l ADMIN [email protected]'s password: BusyBox v1.1.3 (2011.02.12-01:48+0000) Built-in shell (ash) Enter 'help' for a list of built-in commands. # show -sh: show: not found # smash -sh: smash: not found Supermicro support is giving me inconsistent answers. Is it possible to connect to the SOL via the SSH interface?

    Read the article

  • supervise/daemontools conflicts with apache -D FOREGROUND

    - by Kevin G.
    Hoping that somebody can help us understand this behavior. We've got a bunch of daemontools services under /etc/service/. One of the services controls apache, and the run script has this in it. exec envdir /var/lib/supervise/wwwproxy/env setuidgid root bash <<-BASH ulimit -n 8192 # also increase the running user's file descriptor limit exec apache2 -f /path/to/demo_apache2.conf -D FOREGROUND BASH We were having the problem that svc -d /etc/service/* actually had the effect of restarting all the services, it didn't take them down. We finally tracked it down to that one service, and found that svc -d /etc/service/apache2 would bring up any other service was down, including itself. Changing FOREGROUND to NO_DAEMONIZE fixes the behavior, but we'd really like to understand what's going on. Can anybody explain why an svc -d on one service would bring an other service up? Thanks for any clue you can offer.

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >