Search Results

Search found 325 results on 13 pages for 'bs'.

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

  • Postfix sendmail -bs shows no output - permissions?

    - by Tatu Ulmanen
    When I run the sendmail -bs command as root, I get the expected output: $ sudo sendmail -bs 220 mydomain.com ESMTP Postfix ehlo localhost 250-mydomain.com 250-PIPELINING 250-SIZE 15728640 250-ETRN 250-ENHANCEDSTATUSCODES 250-8BITMIME 250 DSN But when I run the same command without sudo, I get no output at all and sendmail doesn't respond to any commands: $ sendmail -bs ehlo localhost quit wtf ^C $ How can I configure Postfix so that sendmail works for every user (or at least for some specific users)? I need this because SwiftMailer for PHP uses sendmail -bs for sending mails and fails when it can't find any output.

    Read the article

  • Throughput = BS * IOPS?

    - by Marvin
    I've seen in many places that throughput = bs * iops should be true. For example writing at 128k block size to a SAS disk that can support 190 IOPS should give a throughput of ~23 MBps - 23.75(MBs) = 128(BS)*190(SAS-15 IOPS)/1024. Now when I tested it in a VM against a monster NetApp filer I got theses results: # dd if=/dev/zero of=/tmp/dd.out bs=4k count=2097152 8589934592 bytes (8.6 GB) copied, 61.5996 seconds, 139 MB/s To view the IO rate of the VM I used iostat and esxtop, and they both showed around 250 IOPS. So to my understanding the throughput was supposed to be ~1000k: 1000(KBs) = 4(BS)*250(IOPS). dd of 8GB is twice the size of RAM of course, so no page caching here. What am I missing? Thanks!

    Read the article

  • from MS Biology to BS Computer Science [on hold]

    - by Air Borne
    I'm Marco from Italy and I'd like to ask you a piece of advice about my career. I hold a Ms degree in Biology, I enjoyed a lot studying it and I got very good grades but I didn't know what to do with my degree in the real life. Few months ago, I began to read a book about Python programming (Introduction to Computer Science, Zelle J.) and I've great fun learning Python as a beginner, I wake up in the morning thinking about doing excersies and writing simple programs with python :) I'm also watching free lectures from MIT open courseware, and I'm feeling a certain degree of regrets for never asking myself what was computer science, since it seems to me it's a magic world. After weeks of doubts, I made a move :) I applied for a CS bachelor degree abroad, I got an interview and I'm going to start this great adventure next September. I feel incredibly excited at it, but a little bit scared too. Scared because sometimes I think I'm making a great mistake for my life restarting from a bachelor in a completely different area of study. Sometimes I hear people saying the IT market is bad, sometimes I hear other ones saying quite the opposite instead. Moreover, some colleagues of mine suggested me to try to get into Bioinformatics, instead of CS. My question is: I want to really discover if CS is for me, I mean the passion of my life. I know I'm just a beginner and I can't say nothing about it yet. What do you suggest me: CS or Bioinformatics? If I get a Bs in CS, could I get into bioinformatics without relevant experience, taking into account I have a Ms Biology degree? Any comment is appreciated, thanks in advance.

    Read the article

  • KVM guest io is much slower than host io: is that normal?

    - by Evolver
    I have a Qemu-KVM host system setup on CentOS 6.3. Four 1TB SATA HDDs working in Software RAID10. Guest CentOS 6.3 is installed on separate LVM. People say that they see guest performance almost equal to host performance, but I don't see that. My i/o tests are showing 30-70% slower performance on guest than on host system. I tried to change scheduler (set elevator=deadline on host and elevator=noop on guest), set blkio.weight to 1000 in cgroup, change io to virtio... But none of these changes gave me any significant results. This is a guest .xml config part: <disk type='file' device='disk'> <driver name='qemu' type='raw'/> <source file='/dev/vgkvmnode/lv2'/> <target dev='vda' bus='virtio'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/> </disk> There are my tests: Host system: iozone test # iozone -a -i0 -i1 -i2 -s8G -r64k random random KB reclen write rewrite read reread read write 8388608 64 189930 197436 266786 267254 28644 66642 dd read test: one process and then four simultaneous processes # dd if=/dev/vgkvmnode/lv2 of=/dev/null bs=1M count=1024 iflag=direct 1073741824 bytes (1.1 GB) copied, 4.23044 s, 254 MB/s # dd if=/dev/vgkvmnode/lv2 of=/dev/null bs=1M count=1024 iflag=direct skip=1024 & dd if=/dev/vgkvmnode/lv2 of=/dev/null bs=1M count=1024 iflag=direct skip=2048 & dd if=/dev/vgkvmnode/lv2 of=/dev/null bs=1M count=1024 iflag=direct skip=3072 & dd if=/dev/vgkvmnode/lv2 of=/dev/null bs=1M count=1024 iflag=direct skip=4096 1073741824 bytes (1.1 GB) copied, 14.4528 s, 74.3 MB/s 1073741824 bytes (1.1 GB) copied, 14.562 s, 73.7 MB/s 1073741824 bytes (1.1 GB) copied, 14.6341 s, 73.4 MB/s 1073741824 bytes (1.1 GB) copied, 14.7006 s, 73.0 MB/s dd write test: one process and then four simultaneous processes # dd if=/dev/zero of=test bs=1M count=1024 oflag=direct 1073741824 bytes (1.1 GB) copied, 6.2039 s, 173 MB/s # dd if=/dev/zero of=test bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test2 bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test3 bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test4 bs=1M count=1024 oflag=direct 1073741824 bytes (1.1 GB) copied, 32.7173 s, 32.8 MB/s 1073741824 bytes (1.1 GB) copied, 32.8868 s, 32.6 MB/s 1073741824 bytes (1.1 GB) copied, 32.9097 s, 32.6 MB/s 1073741824 bytes (1.1 GB) copied, 32.9688 s, 32.6 MB/s Guest system: iozone test # iozone -a -i0 -i1 -i2 -s512M -r64k random random KB reclen write rewrite read reread read write 524288 64 93374 154596 141193 149865 21394 46264 dd read test: one process and then four simultaneous processes # dd if=/dev/mapper/VolGroup-lv_home of=/dev/null bs=1M count=1024 iflag=direct skip=1024 1073741824 bytes (1.1 GB) copied, 5.04356 s, 213 MB/s # dd if=/dev/mapper/VolGroup-lv_home of=/dev/null bs=1M count=1024 iflag=direct skip=1024 & dd if=/dev/mapper/VolGroup-lv_home of=/dev/null bs=1M count=1024 iflag=direct skip=2048 & dd if=/dev/mapper/VolGroup-lv_home of=/dev/null bs=1M count=1024 iflag=direct skip=3072 & dd if=/dev/mapper/VolGroup-lv_home of=/dev/null bs=1M count=1024 iflag=direct skip=4096 1073741824 bytes (1.1 GB) copied, 24.7348 s, 43.4 MB/s 1073741824 bytes (1.1 GB) copied, 24.7378 s, 43.4 MB/s 1073741824 bytes (1.1 GB) copied, 24.7408 s, 43.4 MB/s 1073741824 bytes (1.1 GB) copied, 24.744 s, 43.4 MB/s dd write test: one process and then four simultaneous processes # dd if=/dev/zero of=test bs=1M count=1024 oflag=direct 1073741824 bytes (1.1 GB) copied, 10.415 s, 103 MB/s # dd if=/dev/zero of=test bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test2 bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test3 bs=1M count=1024 oflag=direct & dd if=/dev/zero of=test4 bs=1M count=1024 oflag=direct 1073741824 bytes (1.1 GB) copied, 49.8874 s, 21.5 MB/s 1073741824 bytes (1.1 GB) copied, 49.8608 s, 21.5 MB/s 1073741824 bytes (1.1 GB) copied, 49.8693 s, 21.5 MB/s 1073741824 bytes (1.1 GB) copied, 49.9427 s, 21.5 MB/s I wonder is that normal situation or did I missed something?

    Read the article

  • BS in CS. Are specializations worth it?

    - by CheesePls
    I'm currently pursuing my BS in Computer Science and my school offers specializations based upon taking certain advanced electives. I was thinking about getting two of them since they are sort of on the way to my degree anyway. They are Software Engineering and Programming Languages and Compilers . Would these specializations actually be useful in finding a job? Would employers even care about them?

    Read the article

  • Google GWT cross-browser support: is it BS ?

    - by Tim
    I developed a browser-deployed full-text search app in FlashBuilder which communicates RESTfully with a remote web-server. The software fits into a tiny niche--it is for use with ancient languages not modern ones, and there's no way I'm going to make any money on it but I did spend a lot of time on it. Now that Apple won't allow Flash on the iPad, I'm looking for a 100% javascript solution and was led to consider GWT. It looked promising, but one of the apps being "showcased" as a stellar example of what can be done with GWT has this disclaimer on their website (names {removed} to protect the potentially innocent) : Your current web browser (Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/532.5 (KHTML, like Gecko) Chrome/4.1.249.1045 Safari/532.5) is not officially supported by {company and product name were here}. If you experience any problems using this site please install either Microsoft Internet Explorer 6+ or Mozilla Firefox 3.5+ before contacting {product name was here} Support. What gives when GWT apps aren't "officially" supported on Chrome? What grade (A, B, C, D, F) would you give to GWT for cross-browser support? For folks who don't get these kinds of letter grades, A is "excellent" and "F" is failure, and "C" is average. Thanks for your opinions.

    Read the article

  • Importance of certifications for Java programmer without BS degree?

    - by programmx10
    I've read some posts here and other places about how a lot of people don't put much value in certifications but I am beginning to think it may be necessary for me at this point to be able to move to a bigger company, etc. I currently work as a Java programmer with a startup and worked with a small company before that. Now that I'm applying with larger companies the hr people / recruiters have been asking a lot about certifications and some have directly suggested that someone in my position should probably get a few (they were trying to be helpful) since I haven't completed a BS degree yet (I bounced around a bit in college and ended up not finishing but have enough units to finish eventually, just its not something I can do nearly as easily as getting certifications). Anyways, just curious about what people think for someone in my situation where I do have an interested in working for large companies and do not currently have a BS degree (but do have experience already in the field). Any advice on which certifications beyond the SCJP would be appreciated as well

    Read the article

  • Memory leak while asynchronously loading BitmapSource images

    - by harry
    I have a fair few images that I'm loading into a ListBox in my WPF application. Originally I was using GDI to resize the images (the originals take up far too much memory). That was fine, except they were taking about 400ms per image. Not so fine. So in search of another solution I found a method that uses TransformedBitmap (which inherits from BitmapSource). That's great, I thought, I can use that. Except I'm now getting memory leaks somewhere... I'm loading the images asynchronously using a BackgroundWorker like so: BitmapSource bs = ImageUtils.ResizeBitmapSource(ImageUtils.GetImageSource(photo.FullName)); //BitmapSource bs = ImageUtils.GetImageSource(photo.FullName); bs.Freeze(); this.dispatcher.Invoke(new Action(() => { photo.Source = bs; })); GetImageSource just gets the Bitmap from the path and then converts to BitmapSource. Here's the code snippet for ResizeBitmapSource: const int thumbnailSize = 200; int width; int height; if (bs.Width > bs.Height) { width = thumbnailSize; height = (int)(bs.Height * thumbnailSize / bs.Width); } else { height = thumbnailSize; width = (int)(bs.Width * thumbnailSize / bs.Height); } BitmapSource tbBitmap = new TransformedBitmap(bs, new ScaleTransform(width / bs.Width, height / bs.Height, 0, 0)); return tbBitmap; That code is essentially the code from: http://rongchaua.net/blog/c-wpf-fast-image-resize/ Any ideas what could be causing the leak?

    Read the article

  • What are some respectable online colleges to get my BS in Software Engineering? [closed]

    - by Charity
    I have an AA in Social Science and want to earn my BS in Software Engineering. However, I work full time and have a family to support, so my only option is online. I'm really considering Colorado Technical University. They promote a program called Bachelor of Science in Software Engineering on their website and Google searches, however, while I'm filling out the application; the program is actually called Bachelor of Science in Information Technology with a concentration in Software Systems Engineering Specialization. This shoots up a red flag for me. I spent the past week looking online for all kinds of schools and would prefer to go to a "brick and mortar" school's online program, however those only seem to be for international students, which I am not. Living in Colorado Springs, CO (and being prior Army) there are tons of Government DOD contractors, Lockheed Martin, Boeing, etc... that need software engineers and I'm just not sure what school they would like to see me coming from. Not only a reputable school, but also one that has great programs and will teach me real world situations and actually prepare me for my career. I would greatly appreciate any and all information or help you can offer.

    Read the article

  • We are hiring (take a minute to read this, is not another BS talk ;) )

    - by gsusx
    I really wanted to wait until our new website was out to blog about this but I hope you can put up with the ugly website for a few more days J. Tellago keeps growing and, after a quick break at the beginning of the year, we are back in hiring mode J. We are currently expanding our teams in the United States and Argentina and have various positions open in the following categories. .NET developers: If you are an exceptional .NET programmer with a passion for creating great software solutions working...(read more)

    Read the article

  • Reducing Time Complexity in Java

    - by Koeneuze
    Right, this is from an older exam which i'm using to prepare my own exam in january. We are given the following method: public static void Oorspronkelijk() { String bs = "Dit is een boodschap aan de wereld"; int max = -1; char let = '*'; for (int i=0;i<bs.length();i++) { int tel = 1; for (int j=i+1;j<bs.length();j++) { if (bs.charAt(j) == bs.charAt(i)) tel++; } if (tel > max) { max = tel; let = bs.charAt(i); } } System.out.println(max + " keer " + let); } The questions are: what is the output? - Since the code is just an algorithm to determine the most occuring character, the output is "6 keer " (6 times space) What is the time complexity of this code? Fairly sure it's O(n²), unless someone thinks otherwise? Can you reduce the time complexity, and if so, how? Well, you can. I've received some help already and managed to get the following code: public static void Nieuw() { String bs = "Dit is een boodschap aan de wereld"; HashMap<Character, Integer> letters = new HashMap<Character, Integer>(); char max = bs.charAt(0); for (int i=0;i<bs.length();i++) { char let = bs.charAt(i); if(!letters.containsKey(let)) { letters.put(let,0); } int tel = letters.get(let)+1; letters.put(let,tel); if(letters.get(max)<tel) { max = let; } } System.out.println(letters.get(max) + " keer " + max); } However, I'm uncertain of the time complexity of this new code: Is it O(n) because you only use one for-loop, or does the fact we require the use of the HashMap's get methods make it O(n log n) ? And if someone knows an even better way of reducing the time complexity, please do tell! :)

    Read the article

  • Is there any other efficient way to use table variable instead of using temporary table

    - by varta shrimali
    we are writing script to display banners on a web page where we are using temporary table in mysql procedure. Is there any other efficient way to use table variable instead of using temporary table we are using following code: -- banner location CURSOR -- DECLARE banner_location_cursor CURSOR FOR select bm.id as masterId, bm.section as masterName, bs.id as locationId, bs.sectionName as locationName from banner_master as bm inner join banner_section as bs on bm.id=bs.masterId where bm.section=sCode ; -- DECLARE banner CURSORS DECLARE banner_cursor CURSOR FOR SELECT bd.id as bannerId, bd.sectionId, bd.bannerName, bd.websiteURL, bd.paymentType, bd.status, bd.startDate, bd.endDate, bd.bannerDisplayed, bs.id, bs.sectionName from banner_detail as bd inner join banner_section as bs on bs.id=bd.sectionId where bs.id= location_id and bd.status='A' and (dates between cast(bd.startDate as DATE) and cast(bd.endDate as DATE)) order by rand(), bd.bannerDisplayed asc limit 1 ; DECLARE CONTINUE HANDLER FOR NOT FOUND SET no_more_rows = 1; SET dates = (select curdate()); -- RESULTS TABLE WHICH WILL BE RETURNED -- CREATE temporary TABLE test ( b_id INT, s_id INT, b_name varchar(128), w_url varchar(128), p_type varchar(128), st char(1), s_date datetime, e_date datetime, b_display int, sec_id int, s_name varchar(128) ); -- OPEN banner location CURSOR OPEN banner_location_cursor; the_loop: LOOP FETCH banner_location_cursor INTO master_id, master_name, location_id, location_name; IF no_more_rows THEN CLOSE banner_location_cursor; leave the_loop; END IF; OPEN banner_cursor; -- select FOUND_ROWS(); the_loop2: LOOP FETCH banner_cursor INTO banner_id, section_id, banner_name, website_url, payment, status, start_date, end_date, banner_displayed, sec_id, section_name; IF no_more_rows THEN set no_more_rows = 0; CLOSE banner_cursor; leave the_loop2; END IF; INSERT INTO test ( b_id, s_id, b_name , w_url, p_type, st, s_date, e_date, b_display, sec_id, s_name ) VALUES ( banner_id, section_id, banner_name, website_url, payment, status, start_date, end_date, banner_displayed, sec_id, section_name ); UPDATE banner_detail set bannerDisplayed = (banner_displayed+1) where id = banner_id; END LOOP the_loop2; END LOOP the_loop; -- RETURN result SELECT * FROM test; -- DROP RESULTS TABLE DROP TABLE test; END

    Read the article

  • Linq2SQL or EntityFramework and databinding

    - by rene marxis
    is there some way to do databinding with linq2SQL or EntityFramework using "typed links" to the bound property? Public Class Form1 Dim db As New MESDBEntities 'datacontext/ObjectContext Dim bs As New BindingSource Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load bs.DataSource = (From m In db.PROB_GROUP Select m) grid.DataSource = bs TextBox1.DataBindings.Add("Text", bs, "PGR_NAME") TextBox1.DataBindings.Add("Text", bs, db.PROB_GROUP) '**<--- Somthing like this** End Sub End Class I'd like to have type checking when compiling and the model changed.

    Read the article

  • gdb + nasm debug info not being created

    - by cpowel2
    I am relatively new to assembly language programming and am trying to debug a small .asm file that I wrote in Ubuntu. I am however running into an issue where my symbol table is not being loaded and was looking for some help. I am compiling my program as follows. nasm -f elf -g -F dwarf bs.asm gcc -m32 -g bs.o -o bs which produces the executable bs when I run gdb bs I get a message that says no debugging symbols and when I try to set a break point by b main it says function not defined even though its in the file and I can run it using ./bs I read a couple posts that suggested adding the -F dwarf when assembling but that didn't help if anyone has any insight I would greatly appreciated your input. Thanks in advance

    Read the article

  • Are there any jobs for software developers with a BA and no previous employment? [closed]

    - by IDWMaster
    Are there any careers available for developers who have never been employed before in the industry, and who have a BA, rather than a BS in computer science? I'm currently pursuing a BS in computer science but realized that the math is too difficult for me. Someone suggested switching to a BA instead but I have not been able to find any jobs in my state (Minnesota) which take a BA. I was wondering if a BA is worth pursuing if I cannot get a BS.

    Read the article

  • Data layer refactoring

    - by Joey
    I've taken control of some entity framework code and am looking to refactor it. Before I do, I'd like to check my thoughts are correct and I'm not missing the entity-framework way of doing things. Example 1 - Subquery vs Join Here we have a one-to-many between As and Bs. Apart from the code below being hard to read, is it also inefficient? from a in dataContext.As where ((from b in dataContext.Bs where b.Text.StartsWith(searchText) select b.AId).Distinct()).Contains(a.Id) select a Would it be better, for example, to use the join and do something like this? from a in dataContext.As where a.Bs.Any(b => b.Text.StartsWith(searchText)) select a Example 2 - Explicit Joins vs Navigation Here we have a one-to-many between As and Bs and a one-to-many between Bs and Cs. from a in dataContext.As join b in dataContext.Bs on b.AId equals a.Id join c in dataContext.Cs on c.BId equals b.Id where c.SomeValue equals searchValue select a Is there a good reason to use explicit joins rather than navigating through the data model? For example: from a in dataContext.As where a.Bs.Any(b => b.Cs.Any(c => c.SomeValue == searchValue) select a

    Read the article

  • Types in Union or Concat cannot be constructed with hierarchy

    - by user927777
    I am trying to run a query very similar to the following: (from bs in DataContext.TblBookShelf join b in DataContext.Book on bs.BookID equals b.BookID where bs.BookShelfID == bookShelfID select new BookItem { Categories = String.Join("<br/>", b.BookCategories.Select(x => x.Name).DefaultIfEmpty().ToArray()), Name = b.Name, ISBN = b.ISBN, BookType = "Shelf" }).Union(from bs in DataContext.TblBookShelf join bi in DataContext.TblBookInventory on bs.BookID equals bi.BookID select new BookItem { Categories = String.Join("<br/>", bi.BookCategories.Select(x => x.Name).DefaultIfEmpty().ToArray()), Name = bi.Name, ISBN = bi.ISBN, BookType = "Inventory" }); I am receiving "Types in Union or Concat cannot be constructed with hierarchy" after the statement executes, I need to to be able to get a list of categories to display with each book. If anyone could shed some light on a possible solution, it would be greatly appreciated.

    Read the article

  • How to serialize data from processing.js to rails application ?

    - by railscoder
    Hi I am creating a simple canvas using processing.js , how to pass values from rails application to Processing.js void drawBox(int bx, int by, int bs, int bs){ strokeWeight(3); stroke(50,50,50); // Test if the cursor is over the box if (mouseX > bx-bs && mouseX < bx+bs && mouseY > by-bs && mouseY < by+bs) { bover = true; if(!locked) { fill(181,213,255); } } else { fill(255); bover = false; } fill(192); stroke(64); roundRect(bx, by,80,30,10,10); // put in text if (!isRight) { text("Box Value", x-size+5, y-5); //Here i need to pass value from my controller } else { text("Box Value", x+5, y-5); //Here i need to pass value from my controller } } Instead of static string "Box Value" , I need to pass the value from the ex @post.name through ajax

    Read the article

  • How to do a hexdump of first track of HDD?

    - by Daniel Gratz
    How would i do a hexdump in Ubuntu for the first track of a HDD? I am looking for a winhex-esque output if that makes sense. The first track has 63 sectors, each 512 bytes long. I tried dd if=/dev/sda bs=1 count=512 | hexdump -C but that only gave me what appears to be the MBR, or first sector of the HDD. I guess i am confused about what bs and count should be. Bs means how many bytes to display and count is how many multiples of bs? Thanks!

    Read the article

  • C # - a variable using the Encrypt md5

    - by Guilherme Cardoso
    When we are dealing with more sensitive data and important as a keyword, it is not appropriate at all stores them in database without encrypting for security reasons.  For this we use MD5  MD5 is an algorithm that allow us to encript an string, but doesn't leave us desencrypt it (not sure if it is already possible, but at least I know there are many databases already having a record).  The method below will return us a variable encrypted with md5. For example: md5_encriptar (pontonetpt.com ");   The result will be: 34efe85d338075834ad41803eb08c0df This way we save tthese encrypted data into a database, and then to make comparisons we often use the method to compare with the records kept. public string md5_encrypt(string md5) { System.Security.Cryptography.MD5CryptoServiceProvider x = new System.Security.Cryptography.MD5CryptoServiceProvider(); byte[] bs = System.Text.Encoding.UTF8.GetBytes(md5); bs = x.ComputeHash(bs); System.Text.StringBuilder s = new System.Text.StringBuilder(); foreach (byte b in bs) { s.Append(b.ToString("x2").ToLower()); } string password = s.ToString(); return password; }

    Read the article

  • noob iPhone "count" frustrations!?!?!

    - by codemonkey
    Okay, I know I must be doing something incredibly stupid here. Here's the sample code (which, when executed within a viewDidLoad block silently crashes... no error output to debug console). NSMutableArray *bs = [NSMutableArray arrayWithCapacity:10]; [bs addObject:[NSNumber numberWithInteger: 2]]; NSLog(@"%@", [bs count]); [bs release]; What am I missing? Oh... and in case anyone is wondering, this code is just me trying to figure out why I can't get the count of an NSMutableArray that actually matters somewhere else in the program.

    Read the article

  • HLSL - Combining textures

    - by b34r
    Hi All, I'm trying to combine two textures in HLSL - specifically, I want to take the alpha values from a base image, and the color data from an overlay image. My pixel shader for this looks like this: float4 PixelShaderFunction(VertexOut input) : COLOR0 { float4 baseColor = tex2D( BaseSampler, input.baseCoords.xy ).rgba; float4 overlayColor = tex2D( OverlaySampler, input.overlayCoords.xy ).rgba; float4 color; color.r = overlayColor.r; color.g = overlayColor.g; color.b = overlayColor.b; color.a = baseColor.a; return color.rgba; } and my blend state looks like this: BlendState bs = new BlendState(); bs.AlphaSourceBlend = Blend.SourceAlpha; bs.AlphaDestinationBlend = Blend.DestinationAlpha; bs.ColorSourceBlend = Blend.SourceColor; bs.ColorDestinationBlend = Blend.DestinationColor; What this leaves me with is a washed out version of what should be the overlay color. I've tried numerous permutations of the BlendState settings, and played with the pixel shader math quite a bit, but to no avail. Can anyone point me in the right direction? Thanks in advance =)

    Read the article

  • Linux not buffering block I/O when the device is not "in use" (i.e. mounted)

    - by Radek Hladík
    I am installing new server and I've found an interesting issue. The server is running Fedora 19 (3.11.7-200.fc19.x86_64 kernel) and is supposed to host a few KVM/Qemu virtual servers (mail server, file server, etc..). The HW is Intel(R) Xeon(R) CPU 5160 @ 3.00GHz with 16GB RAM. One of the most important features will be Samba server and we have decided to make it as virtual machine with almost direct access to the disks. So the real HDD is cached on SSD (via bcache) then raided with md and the final device is exported into the virtual machine via virtio. The virtual machine is again Fedora 19 with the same kernel. One important topic to find out is whether the virtualization layer will not introduce high overload into disk I/Os. So far I've been able to get up to 180MB/s in VM and up to 220MB/s on real HW (on the SSD disk). I am still not sure why the overhead is so big but it is more than the network can handle so I do not care so much. The interesting thing is that I've found that the disk reads are not buffered in the VM unless I create and mount FS on the disk or I use the disks somehow. Simply put: Lets do dd to read disk for the first time (the /dev/vdd is an old Raptor disk 70MB/s is its real speed): [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 36.8038 s, 71.2 MB/s Buffers: 14444 kB Rereading the data shows that they are cached somewhere but not in buffers of the VM. Also the speed increased to "only" 500MB/s. The VM has 4GB of RAM (more that the test file) [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 5.16016 s, 508 MB/s Buffers: 14444 kB [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 5.05727 s, 518 MB/s Buffers: 14444 kB Now lets mount the FS on /dev/vdd and try the dd again: [root@localhost ~]# mount /dev/vdd /mnt/tmp [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 4.68578 s, 559 MB/s Buffers: 2574592 kB [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 1.50504 s, 1.7 GB/s Buffers: 2574592 kB While the first read was the same, all 2.6GB got buffered and the next read was at 1.7GB/s. And when I unmount the device: [root@localhost ~]# umount /mnt/tmp [root@localhost ~]# cat /proc/meminfo | grep Buffers Buffers: 14452 kB [root@localhost ~]# dd if=/dev/vdd of=/dev/null bs=256k count=10000 ; cat /proc/meminfo | grep Buffers 2621440000 bytes (2.6 GB) copied, 5.10499 s, 514 MB/s Buffers: 14468 kB The bcache was disabled while testing and the results are same on faster (newer) HDDs and on SSD (except for the initial read speed of course). To sum it up. When I read from the device via dd first time, it gets read from the disk. Next time I reread it gets cached in the host but not in the guest (thats actually the same issue, more on that later). When I mount the filesystem but try to read the device directly it gets cached in VM (via buffers). As soon as I stop "using" it, buffers are discarded and the device is not cached anymore in the VM. When I looked into buffers value on the host I realized that the situation is the same. The block I/O gets buffered only when the disk is in use, in this case it means "exported to a VM". On host, after all the measurement done: 3165552 buffers On the host, after the VM shutdown: 119176 buffers I know it is not important as the disks will be mounted all the time but I am curious and I would like to know why it is working like this.

    Read the article

  • Why is domU faster than dom0 on IO?

    - by Paco
    I have installed debian 7 on a physical machine. This is the configuration of the machine: 3 hard drives using RAID 5 Strip element size: 1M Read policy: Adaptive read ahead Write policy: Write Through /boot 200 MB ext2 / 15 GB ext3 SWAP 10GB LVM rest (~500GB) emphasized text I installed postgresql, created a big database (over 1GB). I have an SQL request that takes a lot of time to run (a SELECT statement, so it only reads data from the database). This request takes approximately 5.5 seconds to run. Then, I installed XEN, created a domU, with another debian distro. On this OS, I also installed postgresql, with the same database. The same SQL request takes only 2.5 seconds to run. I checked the kernel on both dom0 and domU. uname-a returns "Linux debian 3.2.0-4-amd64 #1 SMP Debian 3.2.41-2+deb7u2 x86_64 GNU/Linux" on both systems. I checked the kernel parameters, which are approximately the same. For those that are relevant, I changed their values to make them match on both systems using sysctl. I saw no changes (the requests still take the same amount of time). After this, I checked the file systems. I used ext3 on domU. Still no changes. I installed hdparm, and ran hdparm -Tt on both systems, on all my partitions on both systems, and I get similar results. Now, I am stuck, I don't know what is different, and what could be the cause of such a big difference. Additional Info: Debian runs on a Dell server PowerEdge 2950 postgresql: 9.1.9 (both dom0 and domU) xen-linux-system: 3.2.0 xen-hypervisor: 4.1 Thanks EDIT: As Krzysztof Ksiezyk suggested, it might be due to some file caching system. I ran the dd command to test both the read and write speed. Here is domU: root@test1:~# dd if=/dev/zero of=/root/dd count=5MB bs=1MB ^C2020+0 records in 2020+0 records out 2020000000 bytes (2.0 GB) copied, 18.8289 s, 107 MB/s root@test1:~# dd if=/root/dd of=/dev/null count=5MB bs=1MB 2020+0 records in 2020+0 records out 2020000000 bytes (2.0 GB) copied, 15.0549 s, 134 MB/s And here is dom0: root@debian:~# dd if=/dev/zero of=/root/dd count=5MB bs=1MB ^C1693+0 records in 1693+0 records out 1693000000 bytes (1.7 GB) copied, 8.87281 s, 191 MB/s root@debian:~# dd if=/root/dd of=/dev/null count=5MB bs=1MB 1693+0 records in 1693+0 records out 1693000000 bytes (1.7 GB) copied, 0.501509 s, 3.4 GB/s What can be the cause of this caching system? And how can we "fix" it? Can we apply it to dom0? EDIT 2: I switched my virtual disk type. To do so I followed this article. I did a dd if=/dev/vg0/test1-disk of=/mnt/test1-disk.img bs=16M Then in /etc/xen/test1.cfg, I changed the disk parameter to use file: instead of phy: it should have removed the file caching, but I still get the same numbers (domU being much faster for Postgres)

    Read the article

  • dd oflag=direct 5x fast

    - by César
    I have Centos 6.2 in server with this specs: 2xCPU 16 Core AMD Opteron 6282 SE 64GB RAM Raid controller H700 1GB cache NV - 2HD 74GB SAS 15Krpm RAID1 stripe 16k (OS Centos 6.2) sda - 4HD 146GB SAS 15Krpm RAID10 stripe 16k (ext4 bs 4096, no barriers) sdb -> /vol01 Raid controller H800 1GB cache nv - MD1200 12HD 300GB SAS 15Krpm RAID10 stripe 256k (For DB Postgres 8.3.18) (ext4 bs 4096, stride 64, stripe-width 384, no barriers) sdc -> /vol02 I'm benchmarking IO speed with dd, and view thah if in RAID10 12 disk exec: dd if=/dev/zero of=DD bs=8M count=10000 oflag=direct 10000+0 records in 10000+0 records out 83886080000 bytes (84 GB) copied, 126,03 s, 666 MB/s but if I remove "oflag=direct" option obtain about 80 MB/s. In read benchmark, results are similar: dd of=/dev/null if=DD bs=8M count=10000 iflag=direct 10000+0 records in 10000+0 records out 83886080000 bytes (84 GB) copied, 79,5918 s, 1,1 GB/s If remove iflag=direct obtain 150MB/s... I don't understand this huge differences, on other machines y don't have this behavior. Can I have some kernel parameter misconfigured? Thanks!

    Read the article

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