Search Results

Search found 30270 results on 1211 pages for 'bart read'.

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

  • C#/.NET Little Wonders: Interlocked Read() and Exchange()

    - by James Michael Hare
    Once again, in this series of posts I look at the parts of the .NET Framework that may seem trivial, but can help improve your code by making it easier to write and maintain. The index of all my past little wonders posts can be found here. Last time we discussed the Interlocked class and its Add(), Increment(), and Decrement() methods which are all useful for updating a value atomically by adding (or subtracting).  However, this begs the question of how do we set and read those values atomically as well? Read() – Read a value atomically Let’s begin by examining the following code: 1: public class Incrementor 2: { 3: private long _value = 0; 4:  5: public long Value { get { return _value; } } 6:  7: public void Increment() 8: { 9: Interlocked.Increment(ref _value); 10: } 11: } 12:  It uses an interlocked increment, as we discuss in my previous post (here), so we know that the increment will be thread-safe.  But, to realize what’s potentially wrong we have to know a bit about how atomic reads are in 32 bit and 64 bit .NET environments. When you are dealing with an item smaller or equal to the system word size (such as an int on a 32 bit system or a long on a 64 bit system) then the read is generally atomic, because it can grab all of the bits needed at once.  However, when dealing with something larger than the system word size (reading a long on a 32 bit system for example), it cannot grab the whole value at once, which can lead to some problems since this read isn’t atomic. For example, this means that on a 32 bit system we may read one half of the long before another thread increments the value, and the other half of it after the increment.  To protect us from reading an invalid value in this manner, we can do an Interlocked.Read() to force the read to be atomic (of course, you’d want to make sure any writes or increments are atomic also): 1: public class Incrementor 2: { 3: private long _value = 0; 4:  5: public long Value 6: { 7: get { return Interlocked.Read(ref _value); } 8: } 9:  10: public void Increment() 11: { 12: Interlocked.Increment(ref _value); 13: } 14: } Now we are guaranteed that we will read the 64 bit value atomically on a 32 bit system, thus ensuring our thread safety (assuming all other reads, writes, increments, etc. are likewise protected).  Note that as stated before, and according to the MSDN (here), it isn’t strictly necessary to use Interlocked.Read() for reading 64 bit values on 64 bit systems, but for those still working in 32 bit environments, it comes in handy when dealing with long atomically. Exchange() – Exchanges two values atomically Exchange() lets us store a new value in the given location (the ref parameter) and return the old value as a result. So just as Read() allows us to read atomically, one use of Exchange() is to write values atomically.  For example, if we wanted to add a Reset() method to our Incrementor, we could do something like this: 1: public void Reset() 2: { 3: _value = 0; 4: } But the assignment wouldn’t be atomic on 32 bit systems, since the word size is 32 bits and the variable is a long (64 bits).  Thus our assignment could have only set half the value when a threaded read or increment happens, which would put us in a bad state. So instead, we could write Reset() like this: 1: public void Reset() 2: { 3: Interlocked.Exchange(ref _value, 0); 4: } And we’d be safe again on a 32 bit system. But this isn’t the only reason Exchange() is valuable.  The key comes in realizing that Exchange() doesn’t just set a new value, it returns the old as well in an atomic step.  Hence the name “exchange”: you are swapping the value to set with the stored value. So why would we want to do this?  Well, anytime you want to set a value and take action based on the previous value.  An example of this might be a scheme where you have several tasks, and during every so often, each of the tasks may nominate themselves to do some administrative chore.  Perhaps you don’t want to make this thread dedicated for whatever reason, but want to be robust enough to let any of the threads that isn’t currently occupied nominate itself for the job.  An easy and lightweight way to do this would be to have a long representing whether someone has acquired the “election” or not.  So a 0 would indicate no one has been elected and 1 would indicate someone has been elected. We could then base our nomination strategy as follows: every so often, a thread will attempt an Interlocked.Exchange() on the long and with a value of 1.  The first thread to do so will set it to a 1 and return back the old value of 0.  We can use this to show that they were the first to nominate and be chosen are thus “in charge”.  Anyone who nominates after that will attempt the same Exchange() but will get back a value of 1, which indicates that someone already had set it to a 1 before them, thus they are not elected. Then, the only other step we need take is to remember to release the election flag once the elected thread accomplishes its task, which we’d do by setting the value back to 0.  In this way, the next thread to nominate with Exchange() will get back the 0 letting them know they are the new elected nominee. Such code might look like this: 1: public class Nominator 2: { 3: private long _nomination = 0; 4: public bool Elect() 5: { 6: return Interlocked.Exchange(ref _nomination, 1) == 0; 7: } 8: public bool Release() 9: { 10: return Interlocked.Exchange(ref _nomination, 0) == 1; 11: } 12: } There’s many ways to do this, of course, but you get the idea.  Running 5 threads doing some “sleep” work might look like this: 1: var nominator = new Nominator(); 2: var random = new Random(); 3: Parallel.For(0, 5, i => 4: { 5:  6: for (int j = 0; j < _iterations; ++j) 7: { 8: if (nominator.Elect()) 9: { 10: // elected 11: Console.WriteLine("Elected nominee " + i); 12: Thread.Sleep(random.Next(100, 5000)); 13: nominator.Release(); 14: } 15: else 16: { 17: // not elected 18: Console.WriteLine("Did not elect nominee " + i); 19: } 20: // sleep before check again 21: Thread.Sleep(1000); 22: } 23: }); And would spit out results like: 1: Elected nominee 0 2: Did not elect nominee 2 3: Did not elect nominee 1 4: Did not elect nominee 4 5: Did not elect nominee 3 6: Did not elect nominee 3 7: Did not elect nominee 1 8: Did not elect nominee 2 9: Did not elect nominee 4 10: Elected nominee 3 11: Did not elect nominee 2 12: Did not elect nominee 1 13: Did not elect nominee 4 14: Elected nominee 0 15: Did not elect nominee 2 16: Did not elect nominee 4 17: ... Another nice thing about the Interlocked.Exchange() is it can be used to thread-safely set pretty much anything 64 bits or less in size including references, pointers (in unsafe mode), floats, doubles, etc.  Summary So, now we’ve seen two more things we can do with Interlocked: reading and exchanging a value atomically.  Read() and Exchange() are especially valuable for reading/writing 64 bit values atomically in a 32 bit system.  Exchange() has value even beyond simply atomic writes by using the Exchange() to your advantage, since it reads and set the value atomically, which allows you to do lightweight nomination systems. There’s still a few more goodies in the Interlocked class which we’ll explore next time! Technorati Tags: C#,CSharp,.NET,Little Wonders,Interlocked

    Read the article

  • How can I refresh a document I have open in Excel in read-only mode?

    - by RoboShop
    I have an Excel document that is stored on a SharePoint Server, which I always have open on my computer in read-only mode because I need to refer to it. Every so often, in order to get the latest changes, I have to close down the file and reload it again. Are there any options within Excel 2007 which allow me to simply refresh a document I have open in read-only mode to the latest version on the server? Better still, is there a way where this could be done dynamically, without me having to hit refresh?

    Read the article

  • Debian crashed, file system is read-only and cannot backup - How Do I find/mount a USB drive?

    - by Spiros
    We have a Debian server (vm's) here at work and the server crashed after a power failure. I can only boot the system in maintenance mode, and the whole file system is set to read only. I can run fsck though maintenance mode, however I would like to get a backup of some files before I do. Problem: I cannot access the net since there is no network connectivity in maintenance mode, and for some reason I try to add a USB flash drive to the computer but I can't find it through the console. Question: how to you find/mount a usb drive on Debian? I have tried several resources from the internet but nothing worked. Is there any other way I could get a backup of my files? I cannot start networking since the filesystem is set to read only. Any help would be appreciated.

    Read the article

  • Can't read .cso files but I can read their .hlsl versions?

    - by Jader J Rivera
    Well I've been trying to read a .cso file to use as a shader for a DirectX program I'm currently making. Problem is no matter how I implemented a way to read the file it never worked. And after fidgeting around I discover that it's only the .cso files I can't read. I can read anything else (which means it works) even their .hlsl files. Which is strange because the .hlsl (high level shader language) files are supposed to turn into .cso (compiled shader object) files. What I'm currently doing is: vector<byte> Read(string File){ vector<byte> Text; fstream file(File, ios::in | ios::ate | ios::binary); if(file.is_open()){ Text.resize(file.tellg()); file.seekg(0 , ios::beg); file.read(reinterpret_cast<char*>(&Text[0]), Text.size()); file.close(); } return Text; }; If I then implement it. Read("VertexShader.hlsl"); //Works Read("VertexShader.cso"); //Doesn't Works?!?! And I need the .cso version of the shader to draw my sexy triangles. Without it my life and application will never continue and I have no idea what could be wrong. (I've also asked this at stack overflow but still no answers.)

    Read the article

  • Advice on choosing a book to read

    - by Kioshiki
    I would like to ask for some recommendations on useful books to read. Initially I had intended on posting quite a long description of my current issue and asking for advice. But I realised that I didn’t have a clear idea of what I wanted to ask. One thing that is clear to me is that my knowledge in various areas needs improving and reading is one method of doing that. Though choosing the right book to read seems like a task in itself when there are so many books out there. I am a programmer but I also deal with analysis, design & testing. So I am not sure what type of book to read. One option might be to work through two books at the same time. I had thought maybe one about design or practices and another of a more technical focus. Recently I came across one book that I thought might be useful to read: http://xunitpatterns.com/index.html It seems like an interesting book, but the comments I read on amazon.co.uk show that the book is probably longer than it needs to be. Has anyone read it and can comment on this? Another book that I already own and would probably be a good one to finish reading is this: http://www.amazon.co.uk/Code-Complete-Practical-Handbook-Construction/dp/0735619670/ref=sr_1_1?ie=UTF8&qid=1309438553&sr=8-1 Has anyone else read this who can comment on its usefulness? Beyond these two I currently have no clear idea of what to read. I have thought about reading a book related to OO design or the GOF design patterns. But I wonder if I am worrying too much about the process and practices and not focusing on the actual work. I would be very grateful for any suggestions or comments. Many Thanks, Kioshiki

    Read the article

  • SQL SERVER – Read Only Files and SQL Server Management Studio (SSMS)

    - by pinaldave
    Just like any other Developer or DBA SQL Server Management Studio is my favorite application. Any any moment of the time I have multiple instances of the same application are open and I am working on it. Recently, I have come across a very interesting feature in SSMS related to “Read Only” files. I believe it is a little unknown feature as well so decided to write a blog about the same. First create a read only SQL file. You can make any file read by Right Click >> Properties >> Select Attribute Read Only. Now open the same file in SQL Server Management Studio. You will find that besides the file name there is a small ‘lock’ icon. This small icon indicates that the file is read only. Now let us attempt to edit the read only file. It will let us edit the file any way we want, however when we attempt to save it, it gives following pop-up value. The options in the pop-up are self explanatory and I liked it. The goal of the read only file is to prevent users to make un-intended changes. However, when a user should have complete control over the user file. User should be aware that the file is read only but if he wants to edit the file or save as a new file the choices should be present in front of it and the pop-up menu precisely captures the same. Now let us check option related to this feature in SSMS. Go to Menu >> Options >> Environment >> Documents You will find the third option which is “Allow editing of read-only files; warn when attempt to save”. In the above scenario it was already checked. Let us uncheck the same and do the same exercise which we have done earlier. I closed all the earlier window to avoid confusion. With the new option selected when I attempt to even modify the Read Only file, it gives me totally different pop up screen. It gives me an option like “Edit In-Memory”, “Make Writeable” etc. When you select “Edit In-Memory” it allows you to edit the file and later you can save as new file – just like the earlier scenario which we have discussed. . If clicked on the Make Writeable it will remove the restriction of the Read Only and file can be edited as pleased. Reference: Pinal Dave (http://blog.SQLAuthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Query, SQL Server, SQL Server Management Studio, SQL Tips and Tricks, T SQL, Technology

    Read the article

  • AWR Performance Report and Read by Other Session Waits

    - by user702295
    For the questions regarding "read by other session" and its relation to "db file sequential/scattered read", the logic is like this: When a "db file sequential/scattered read" is done, the blocks are either already in the cache or on the disk.  Since any operation on blocks is done in the cache and since and the issue is "read by other session" I will relate to the case the blocks are on the disk. Process A is reading the needed block from the disk to the cache.  During that time, if process B (and C and others) need the same block, it will wait on "read by other session".  A and B can be threads of the same process running in parallel or unrelated processes.  For example two processes doing full table scan on mdp_matrix etc. Solutions for that can be lowering the number of processes competing on the same blocks, increasing PCTFREE.  If it is a full table scan, maybe an index is missing that can result in less blocks being read from the cache and so on.

    Read the article

  • Bluray Drives: 2x vs 4x vs 6x vs 8x read/writespeed.

    - by Wesley
    Hi all, I couldn't find a duplicate question, but I was wondering what the differences are between different read/write speeds for Bluray drive. I'm planning on buying one for a build but don't know if I can cheap out on getting a Bluray 2x drive or spend more money for a quality Bluray 8x drive. Will I just experience more lag/buffering times for Bluray discs on a 2x and none for a 6x or 8x? Thanks in advance.

    Read the article

  • TS-7800 Hangs on bootup

    - by Reid
    I have a TS-7800, and it typically boots from the SD card inserted in it. When I tried to boot it up today, it hung on the syslog line. I am now having "Read only file system" problems. What has gone wrong? Bootup console: >> Copyright (c) 2008, Technologic Systems >> Booting from SD card... . . . . >> Booting to SD Card... INIT: version 2.86 booting Starting the hotplug events dispatcher: udevd. Synthesizing the initial hotplug events...done. Waiting for /dev to be fully populated...done. mount: can't find / in /etc/fstab or /etc/mtab Cleaning up ifupdown...rm: cannot remove `/etc/network/run/ifstate': Read-only file system Loading kernel modules...done. Checking all file systems... fsck 1.37 (21-Mar-2005) ... done. none on /dev/pts type devpts (rw,gid=5,mode=620) /etc/init.d/rcS: line 39: /tmp/.clean: Read-only file system Setting up networking...done. Setting up IP spoofing protection: rp_filter. Enabling packet forwarding...done. Configuring network interfaces...ifup: failed to open statefile /etc/network/run/ifstate: Read-only file system done. Starting portmap daemon: portmap. /etc/init.d/rcS: line 39: /tmp/.clean: Read-only file system /etc/init.d/rcS: line 24: /var/run/utmp: Read-only file system rm: cannot remove `/var/lib/urandom/random-seed': Read-only file system urandom start: failed. Recovering nvi editor sessions... done. INIT: Entering runlevel: 3 Starting system log daemon: syslogd . Starting kernel log daemon: klogd. Starting MTA: open: Read-only file system touch: cannot touch `/var/lib/exim4/config.autogenerated.tmp': Read-only file system chown: cannot access `/var/lib/exim4/config.autogenerated.tmp': No such file or directory chmod: cannot access `/var/lib/exim4/config.autogenerated.tmp': No such file or directory chmod: changing permissions of `/var/lib/exim4/config.autogenerated': Read-only file system /usr/sbin/update-exim4.conf: line 260: cannot create temp file for here document: Read-only file system /usr/sbin/update-exim4.conf: line 387: /var/lib/exim4/config.autogenerated.tmp: Read-only file system 2002-01-01 01:31:36 Cannot open main log file "/var/log/exim4/mainlog": Read-only file system: euid=0 egid=0 2002-01-01 01:31:36 non-existent configuration file(s): /var/lib/exim4/config.autogenerated.tmp 2002-01-01 01:31:36 Cannot open main log file "/var/log/exim4/mainlog": Read-only file system: euid=0 egid=0 exim: could not open panic log - aborting: see message(s) above Invalid new configfile /var/lib/exim4/config.autogenerated.tmp not installing /var/lib/exim4/config.autogenerated.tmp to /var/lib/exim4/config.autogenerated Starting internet superserver: inetd. Starting OpenBSD Secure Shell server: sshd. Starting NFS common utilities: statdStarting periodic command scheduler: cron/usr/sbin/cron: can't open or create /var/run/crond.pid: Read-only file system . Starting web server (apache2)...(30)Read-only file system: apache2: could not open error log file /var/log/apache2/error.log. Unable to open logs failed! Debian GNU/Linux 3.1 ts7800 ttyS0 ts7800 login:

    Read the article

  • Hyper-V Ubuntu 10.04, Filesystem suddenly becomes Read-Only?

    - by Daniel Upton
    We are running a Ubuntu 10.04 VM on a Hyper-V system, The VM is dedicated to running one of our web applications. We have enabled the Hyper-V drivers in /etc/initramfs-tools/modules like so: hv_vmbus hv_storvsc hv_blkvsc hv_netvsc And updated the kernel image like so: $ update-initramfs -u And all was good... until.. This morning i got a support request that our web application was throwing an error 500, so i checked the logs and nothing was there. Then I remembered that I had seen this on another of our ubuntu servers so I... $ touch foo.txt And my suspicions were confirmed: touch: cannot touch `foo.txt': Read-only file system Why is the filesystem randomly becoming readonly? Is this only in Ubuntu on HV? Is it a problem on RedHat or Cent?

    Read the article

  • SQLAuthority News – Microsoft Whitepaper – AlwaysOn Solution Guide: Offloading Read-Only Workloads to Secondary Replicas

    - by pinaldave
    SQL Server 2012 has many interesting features but the most talked feature is AlwaysOn. Performance tuning is always a hot topic. I see lots of need of the same and lots of business around it. However, many times when people talk about performance tuning they think of it as a either query tuning, performance tuning, or server tuning. All are valid points, but performance tuning expert usually understands the business workload and business logic before making suggestions. For example, if performance tuning expert analysis workload and realize that there are plenty of reports as well read only queries on the server they can for sure consider alternate options for the same. If read only data is not required real time or it can accept the data which is delayed a bit it makes sense to divide the workload. A secondary replica of the original data which can serve all the read only queries and report is a good idea in most of the cases where there is plenty of workload which is not dependent on the real time data. SQL Server 2012 has introduced the feature of AlwaysOn which can very well fit in this scenario and provide a solution in Read-Only Workloads. Microsoft has recently announced a white paper which is based on absolutely the same subject. I recommend it to read for every SQL Enthusiast who is are going to implement a solution to offload read-only workloads to secondary replicas. Download white paper AlwaysOn Solution Guide: Offloading Read-Only Workloads to Secondary Replicas Reference: Pinal Dave (http://blog.sqlauthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Backup and Restore, SQL Query, SQL Server, SQL Tips and Tricks, T SQL, Technology Tagged: AlwaysOn

    Read the article

  • what should I read in Windows [closed]

    - by Umesha MS
    I think I am asking generic question. Being a developer in windows what should I read to improve my skills? Do I need to read concepts on need basis or do I need to read concepts well in advance? If I want to read the concepts in advance then what topics do I need to read. (Note : I am a Windows developer. I use c++ programming language, Win32/MFC frame work and I use Visual studio IDE.) Updated: To be more specific when a fresher comes to my team I will ask him to read the following things and I tell him that these are very important. 1)C++ : 1 The C++ Programming Language by Bjarne Stroustrup's 2 Thinking in C++ 2nd Edition by Bruce Eckel 2)Win32/MFC : 1 Programming Applications for Microsoft Windows by Jeffrey Richter 2 windows programming by charles petzold 3 Programming Windows with MFC –by Jeff Prosise For 2 years and above developer I ask them to read 1)Above concepts (C++ and Win32/MFC)are mandate 2)Design Pattern : 1)Gang Of Four. 2)Head first patter. 3)Design princples. But for above 6 years’ experience developer what are the concepts are important.

    Read the article

  • How do I create a read only MySQL user for backup purposes with mysqldump?

    - by stickmangumby
    I'm using the automysqlbackup script to dump my mysql databases, but I want to have a read-only user to do this with so that I'm not storing my root database password in a plaintext file. I've created a user like so: grant select, lock tables on *.* to 'username'@'localhost' identified by 'password'; When I run mysqldump (either through automysqlbackup or directly) I get the following warning: mysqldump: Got error: 1044: Access denied for user 'username'@'localhost' to database 'information_schema' when using LOCK TABLES Am I doing it wrong? Do I need additional grants for my readonly user? Or can only root lock the information_schema table? What's going on? Edit: GAH and now it works. I may not have run FLUSH PRIVILEGES previously. As an aside, how often does this occur automatically? Edit: No, it doesn't work. Running mysqldump -u username -p --all-databases > dump.sql manually doesn't generate an error, but doesn't dump information_schema. automysqlbackup does raise an error.

    Read the article

  • Read Committed Snapshot Isolation– Two Considerations

    - by GavinPayneUK
      The Read Committed Snapshot database option in SQL Server, known perhaps more accurately as Read Committed Snapshot Isolation or RCSI, can be enabled to help readers from blocking writers and writers from blocking readers.  However, enabling it can cause two issues with the tempdb database which are often overlooked. One can slow down queries, the other can cause queries to fail . Overview of RCSI Enabling the option changes the behaviour of the default SQL Server isolation level, read...(read more)

    Read the article

  • read file in shell script

    - by moata_u
    how can i read file in shell script , then assign each line to an variable that i can use later ,,,(am thinking in way to load an default setting from file) i already try : process (){ } FILE='' read -p "Please enter name of default file : " FILE if [ ! -f $FILE ]; then echo "$FILE : does not exists " exit 1 elif [ ! -r $FILE ]; then echo "$FILE : can not read " fi exec 0<"$FILE" n=0 while read -r line do (assign each line to an variable) done

    Read the article

  • How to read STDIN into string variable until EOF in C?

    - by NovumCoder
    Hi, im getting "Bus Error" trying to read stdin into a char* variable. I just want to read whole stuff coming over stdin and put it first into a variable, then continue working on the variable. My Code is as follows: char* content; char* c; while( scanf( "%c", c)) { strcat( content, c); } fprintf( stdout, "Size: %d", strlen( content)); But somehow i always get "Bus error" returned by calling "cat test.txt | myapp", where "myapp" is the compiled code above. My question is how do i read stdin until EOF into a variable? As you see in the code, i just want to print the size of input coming over stdin, in this case it should be equal to the size of the file "test.txt". I thought just using scanf would be enough, maybe buffered way to read stdin?

    Read the article

  • Mono 2.11 on nginx using fastcgi-mono-server4 will not work

    - by fuzzycow101
    I have mono 2.11 set up with my nginx 1.0.15 webserver running on centos 6.2. I built it from source and xps2, xps4 and fastcgi-mono-server2 work as expected. The problem is when I try and run fastcgi-mono-server4. When I run: fastcgi-mono-server4 /applications=site:/:/srv/www/html/ /socket=tcp:127.0.0.1:9000 /loglevels=Debug /printlog=true Here is what I get from fastcgi-mono-server2: [2012-06-06 23:51:07Z] Debug Record received. (Type: BeginRequest, ID: 1, Length: 8) [2012-06-06 23:51:07Z] Debug Record received. (Type: Params, ID: 1, Length: 801) [2012-06-06 23:51:07Z] Debug Record received. (Type: Params, ID: 1, Length: 0) [2012-06-06 23:51:07Z] Debug Read parameter. (QUERY_STRING = ) [2012-06-06 23:51:07Z] Debug Read parameter. (REQUEST_METHOD = GET) [2012-06-06 23:51:07Z] Debug Read parameter. (CONTENT_TYPE = ) [2012-06-06 23:51:07Z] Debug Read parameter. (CONTENT_LENGTH = ) [2012-06-06 23:51:07Z] Debug Read parameter. (SCRIPT_NAME = /) [2012-06-06 23:51:07Z] Debug Read parameter. (REQUEST_URI = /) [2012-06-06 23:51:07Z] Debug Read parameter. (DOCUMENT_URI = /) [2012-06-06 23:51:07Z] Debug Read parameter. (DOCUMENT_ROOT = /srv/www/html) [2012-06-06 23:51:07Z] Debug Read parameter. (SERVER_PROTOCOL = HTTP/1.1) [2012-06-06 23:51:07Z] Debug Read parameter. (GATEWAY_INTERFACE = CGI/1.1) [2012-06-06 23:51:07Z] Debug Read parameter. (SERVER_SOFTWARE = nginx/1.0.15) [2012-06-06 23:51:07Z] Debug Read parameter. (REMOTE_ADDR = 192.168.128.121) [2012-06-06 23:51:07Z] Debug Read parameter. (REMOTE_PORT = 62326) [2012-06-06 23:51:07Z] Debug Read parameter. (SERVER_ADDR = 192.168.128.125) [2012-06-06 23:51:07Z] Debug Read parameter. (SERVER_PORT = 80) [2012-06-06 23:51:07Z] Debug Read parameter. (SERVER_NAME = site) [2012-06-06 23:51:07Z] Debug Read parameter. (REDIRECT_STATUS = 200) [2012-06-06 23:51:07Z] Debug Read parameter. (PATH_INFO = ) [2012-06-06 23:51:07Z] Debug Read parameter. (SCRIPT_FILENAME = /srv/www/html/) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_HOST = site) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_USER_AGENT = Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20100101 Firefox/13.0) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_ACCEPT = text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_ACCEPT_LANGUAGE = en-us,en;q=0.5) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_ACCEPT_ENCODING = gzip, deflate) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_CONNECTION = keep-alive) [2012-06-06 23:51:07Z] Debug Read parameter. (HTTP_COOKIE = ASP.NET_SessionId=0176BE8FC161E702439D3C91) [2012-06-06 23:51:07Z] Debug Record received. (Type: StandardInput, ID: 1, Length: 0) [2012-06-06 23:51:08Z] Debug Record sent. (Type: StandardOutput, ID: 1, Length: 196) [2012-06-06 23:51:08Z] Debug Record sent. (Type: StandardOutput, ID: 1, Length: 128) [2012-06-06 23:51:08Z] Debug Record sent. (Type: StandardOutput, ID: 1, Length: 0) [2012-06-06 23:51:08Z] Debug Record sent. (Type: EndRequest, ID: 1, Length: 8) And this is what I get from fastcgi-mono-server4: [2012-06-06 23:50:52Z] Debug Record received. (Type: BeginRequest, ID: 1, Length: 8) [2012-06-06 23:50:52Z] Debug Record received. (Type: Params, ID: 1, Length: 801) [2012-06-06 23:50:52Z] Debug Record received. (Type: Params, ID: 1, Length: 0) [2012-06-06 23:50:52Z] Debug Read parameter. (QUERY_STRING = ) [2012-06-06 23:50:52Z] Debug Read parameter. (REQUEST_METHOD = GET) [2012-06-06 23:50:52Z] Debug Read parameter. (CONTENT_TYPE = ) [2012-06-06 23:50:52Z] Debug Read parameter. (CONTENT_LENGTH = ) [2012-06-06 23:50:52Z] Debug Read parameter. (SCRIPT_NAME = /) [2012-06-06 23:50:52Z] Debug Read parameter. (REQUEST_URI = /) [2012-06-06 23:50:52Z] Debug Read parameter. (DOCUMENT_URI = /) [2012-06-06 23:50:52Z] Debug Read parameter. (DOCUMENT_ROOT = /srv/www/html) [2012-06-06 23:50:52Z] Debug Read parameter. (SERVER_PROTOCOL = HTTP/1.1) [2012-06-06 23:50:52Z] Debug Read parameter. (GATEWAY_INTERFACE = CGI/1.1) [2012-06-06 23:50:52Z] Debug Read parameter. (SERVER_SOFTWARE = nginx/1.0.15) [2012-06-06 23:50:52Z] Debug Read parameter. (REMOTE_ADDR = 192.168.128.121) [2012-06-06 23:50:52Z] Debug Read parameter. (REMOTE_PORT = 62326) [2012-06-06 23:50:52Z] Debug Read parameter. (SERVER_ADDR = 192.168.128.125) [2012-06-06 23:50:52Z] Debug Read parameter. (SERVER_PORT = 80) [2012-06-06 23:50:52Z] Debug Read parameter. (SERVER_NAME = site) [2012-06-06 23:50:52Z] Debug Read parameter. (REDIRECT_STATUS = 200) [2012-06-06 23:50:52Z] Debug Read parameter. (PATH_INFO = ) [2012-06-06 23:50:52Z] Debug Read parameter. (SCRIPT_FILENAME = /srv/www/html/) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_HOST = site) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_USER_AGENT = Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20100101 Firefox/13.0) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_ACCEPT = text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_ACCEPT_LANGUAGE = en-us,en;q=0.5) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_ACCEPT_ENCODING = gzip, deflate) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_CONNECTION = keep-alive) [2012-06-06 23:50:52Z] Debug Read parameter. (HTTP_COOKIE = ASP.NET_SessionId=0176BE8FC161E702439D3C91) [2012-06-06 23:50:53Z] Debug Record received. (Type: StandardInput, ID: 1, Length: 0) [2012-06-06 23:50:53Z] Debug Record sent. (Type: EndRequest, ID: 1, Length: 8) I do not see what I am doing wrong. Any help would be great.

    Read the article

  • Read On Phone Pushes Data from Your Desktop to the Appropriate Android App

    - by ETC
    Read On Phone is a free Android application that intelligently pushes data to your phone from your bowser. Rather than simply opening the URL on your phone, it opens the appropriate application for the task and formats text. Most send-to-phone type tools simply take the URL of the web page you’re looking at on your computer and shuttle it to your phone. Read On Phone is a more active and effective tool. When you send a page that is text, it formats the text for easy reading on your phone. When you send a YouTube video, map, or telephone number, it opens up the appropriate tool on your phone such as your YouTube viewer, Google Maps, or your phone dialer. In addition to that handy functionality Read On Phone also includes adjustments for day and night reading, font size, auto-scrolling, and pagination. Read On Phone is available as both a Chrome extension and as a bookmarklet for cross-browser use. Hit up the link below for additional information. Read On Phone Latest Features How-To Geek ETC Should You Delete Windows 7 Service Pack Backup Files to Save Space? What Can Super Mario Teach Us About Graphics Technology? Windows 7 Service Pack 1 is Released: But Should You Install It? How To Make Hundreds of Complex Photo Edits in Seconds With Photoshop Actions How to Enable User-Specific Wireless Networks in Windows 7 How to Use Google Chrome as Your Default PDF Reader (the Easy Way) Read On Phone Pushes Data from Your Desktop to the Appropriate Android App MetroTwit is a Sleek Native Twitter Client for Your Windows System Make Efficient Use of Tab Bar Space by Customizing Tab Width in Firefox See the Geeky Work Done Behind the Scenes to Add Sounds to Movies [Video] Use a Crayon to Enhance Engraved Lettering on Electronics Adult Swim Brings Their Programming Lineup to iOS Devices

    Read the article

  • Using Queries with Coherence Read-Through Caches

    - by jpurdy
    Applications that rely on partial caches of databases, and use read-through to maintain those caches, have some trade-offs if queries are required. Coherence does not support push-down queries, so queries will apply only to data that currently exists in the cache. This is technically consistent with "read committed" semantics, but the potential absence of data may make the results so unintuitive as to be useless for most use cases (depending on how much of the database is held in cache). Alternatively, the application itself may manually "push down" queries to the database, either retrieving results equivalent to querying the cache directly, or may query the database for a key set and read the values from the cache (relying on read-through to handle any missing values). Obviously, if the result set is too large, reading through the cache may cause significant thrashing. It's also worth pointing out that if the cache is asynchronously synchronized with the database (perhaps via database change listener), that an application may commit a transaction to the database, then generate a key set from the database via a query, then read cache entries through the cache, possibly resulting in a race condition where the application sees older data than it had previously committed. In theory this is not problematic but in practice it is very unintuitive. For this reason it often makes sense to invalidate the cache when updating the database, forcing the next read-through to update the cache.

    Read the article

  • How to delete/edit files from readonly filesystem

    - by Santosh Linkha
    I am having problem with my memory device (actually a memory card that act external memory device like pendrive). experimentx@workmateX:/var/www/zendtest$ sudo rm /media/A88F-8788/python-2.7.1-docs-html.zip rm: cannot remove `/media/A88F-8788/python-2.7.1-docs-html.zip': Read-only file system I tried to change the file permission of the system but that doesn't work experimentx@workmateX:/var/www/zendtest$ sudo chmod 0777 /media/A88F-8788/python-2.7.1-docs-html.zip chmod: changing permissions of `/media/A88F-8788/python-2.7.1-docs-html.zip': Read-only file system But it perfectly works on windows. UPDATE On opening the drive and running command sudo mount -o remount,rw /media/A88F-8788 /var/log/syslog: Mar 23 15:29:48 workmateX kernel: [18042.257407] fat_get_cluster: 11 callbacks suppressed Mar 23 15:29:48 workmateX kernel: [18042.257414] FAT: Filesystem error (dev sdb1) Mar 23 15:29:48 workmateX kernel: [18042.257418] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:29:48 workmateX kernel: [18042.257425] FAT: Filesystem has been set read-only Mar 23 15:29:48 workmateX kernel: [18042.258187] FAT: Filesystem error (dev sdb1) Mar 23 15:29:48 workmateX kernel: [18042.258194] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.333787] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.333795] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.335949] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.335957] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.354903] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.354911] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.357213] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.357221] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.359547] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.359555] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.361929] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.361936] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.377416] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.377424] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.379384] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.379392] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.381898] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.381906] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:35 workmateX kernel: [18149.383764] FAT: Filesystem error (dev sdb1) Mar 23 15:31:35 workmateX kernel: [18149.383772] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.569747] fat_get_cluster: 11 callbacks suppressed Mar 23 15:31:40 workmateX kernel: [18154.569754] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.569758] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.569765] FAT: Filesystem has been set read-only Mar 23 15:31:40 workmateX kernel: [18154.572022] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.572029] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.582933] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.582941] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.585921] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.585929] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.587819] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.587827] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.597547] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.597555] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.599503] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.599511] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.602896] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.602905] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.615338] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.615346] fat_get_cluster: invalid cluster chain (i_pos 0) Mar 23 15:31:40 workmateX kernel: [18154.618574] FAT: Filesystem error (dev sdb1) Mar 23 15:31:40 workmateX kernel: [18154.618581] fat_get_cluster: invalid cluster chain (i_pos 0) var/log/message: Mar 23 15:29:48 workmateX kernel: [18042.257407] fat_get_cluster: 11 callbacks suppressed Mar 23 15:31:40 workmateX kernel: [18154.569747] fat_get_cluster: 11 callbacks suppressed

    Read the article

  • How to figure the read/write ratio in Sql Server?

    - by Bill Paetzke
    How can I query the read/write ratio in Sql Server 2005? Are there any caveats I should be aware of? Perhaps it can be found in a DMV query, a standard report, a custom report (i.e the Performance Dashboard), or examining a Sql Profiler trace. I'm not sure exactly. Why do I care? I'm taking time to improve the performance of my web app's data layer. It deals with millions of records and thousands of users. One of the points I'm examining is database concurrency. Sql Server uses pessimistic concurrency by default--good for a write-heavy app. If my app is read-heavy, I might switch it to optimistic concurrency (isolation level: read uncommitted snapshot) like Jeff Atwood did with StackOverflow.

    Read the article

  • What is the difference between connection and read timeout for sockets?

    - by corgrath
    3 questions: 1) What is the difference between connection and read timeout for sockets? 2) What does connection timeout set to "infinity" mean? In what situation can it remain in an infinitive loop? and what can trigger that the infinity-loop dies? 3) What does read timeout set to "infinity" mean? In what situation can it remain in an infinitive loop? and what can trigger that the infinity-loop dies?

    Read the article

  • PHP: Fastest way possible to read contents of a file.

    - by SoLoGHoST
    Ok, I'm looking for the fastest possible way to read all of the contents of a file via php with a filepath on the server, also these files can be huge. So it's very important that it does a READ ONLY to it as fast as possible. Is reading it line by line faster than reading the entire contents? Though, I remember reading up on this some, that reading the entire contents can produce errors for huge files. Is this true?

    Read the article

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