Daily Archives

Articles indexed Thursday May 31 2012

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

  • Flash messages in ASP.NET MVC without sessions

    - by Fernando Correia
    I'm developing a web application for Windows Azure using ASP.NET MVC 4. I would like to enforce one restriction in the architecture: do not use Session. To achieve availability on Azure, and since there is no sticky sessions, I would need to store the session data in some central service, probably either SQL Azure or the Caching Service. I would rather avoid sessions on the SQL database to avoid the increased latency, and the caching service on Azure is very expensive for the ammount of memory offered. On the other hand, I would like to have the ability to easily pass Flash-style messages among redirects. TempData is the recommended way to do this, but by default it uses the session object. So I would like to know: Is there an alternative way to use TempData that doesn't require sessions or shared data between servers? Cookies perhaps? Is there a better alternative I'm overlooking?

    Read the article

  • What is the reason for section 1 of LGPL and what is the implication for section 9.

    - by Roland Schulz
    Why was section 1 added to LGPLv3? My understanding of section 3&4 is, one can convey the combined work under any license and with no requirements from GPLv3 (besides those explicitly stated as requirements in LGPLv3 3&4). Given that, why is section 1 necessary. Wouldn't that sections 3&4 by themselves already imply anyhow what section 1 explicitly states? I assume that I'm missing something and section 1 isn't redundant. Assuming that, does this have implications for other sections in GPLv3? E.g. does conveying a covered work under sections 3&4 fall under the patent clause of section 10 of GPLv3? Why does section 1 not also state an exception for section 10? Put another way. Is the Eigen FAQ correct by stating: LGPL requires [for header only libraries] pretty much the same as the 2-clause BSD license. It it true that for conveying object files including material from LGPLv3 headers no GPLv3 patent clauses apply?

    Read the article

  • Can a language support something like "Retry/Fix"?

    - by Aaron Anodide
    I was just wondering if a language could support something like a Retry/Fix block? The answer to this question is probably the reason it's a bad idea or equivalent to something else, but the idea keeps popping into my head. void F() { try { G(); } fix(WrongNumber wn, out int x) { x = 1; } } void G() { int x = 0; retry<int> { if(x != 1) throw new WrongNumber(x); } } After the fix block ran, the retry block would run again...

    Read the article

  • I can write code...but can't design well. Any suggestions?

    - by user396089
    I feel that I am good at writing code in bits and pieces, but my designs really suck. The question is how do I improve my designs (in order to become a better designer). I think schools and colleges do a good job of teaching people as to how to become good at mathematical problem solving, but lets admit the fact that most programs taught at school are generally around 1000 - 2000 lines long, which means that it is mostly an academic exercise and no way reflects the complexity of real world software (a few hundred thousand to millions of lines of code). This is where I believe that even projects like topcoder/project euler also won't be of much help, they might sharpen your mathematical problem solving ability - but you might become a theoretician programmer; someone who is more interested in the nice, clean stuff, and someone who is utterly un-interested in the day to day mundane and hairy stuff that most application programmers deal with. So my question is how do I improve my design skills? That is the ability to design small/medium scale applications that will go into a few thousand of lines of code? How can I learn design skills that would help me build a better html editor kit, or some graphics program like gimp?

    Read the article

  • Wlan connection got lost permanent

    - by chris
    I have a desktop with a fritz usb wlan n tick and tried ubuntu 12.04. installlation is fine and wlan is working, however connection drops permanent. reconnecting manually fixes it but after a few minutes it drops again. it's connected to a vodafone 802 box with wlan n fix set. it seems that it works when i switch off n mode...but i need to test. can someone confirm or is there another solution? i have another machine with 12.04 (hp 625 laptop) running where connection is stable. any help much appreciated. thank chris

    Read the article

  • Tried every possible method but couldn't enable compiz?

    - by 9kkmin
    a newbie, installed ubuntu 10.10 about a month ago,over the month i fixed everything from dad playback,to webcam,but couldn't enable compiz anayway,my card is blacklisted, i tried the SKIP_CHECKS=yes,method and even tried ghex editing,but of no avail,now all i get when i run compiz in the terminal is "segmentation fault",the specs of my laptop is intel core i3 2330,and intel hd graphics 3000,has anyone has been able to run compiz on intel hd graphics 3000?

    Read the article

  • How to boot live iso images?

    - by virpara
    I found that it can be done with loopback as follows menuentry "Lucid ISO" { loopback loop (hd0,1)/boot/iso/ubuntu-10.04-desktop-i386.iso linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/boot/iso/ubuntu-10.04-desktop-i386.iso noprompt noeject initrd (loop)/casper/initrd.lz } But it works only with ubuntu or its derivatives. How it should be written if I want to boot other live images like fedora, cent, opensuse etc. ? Edit: I found some other entries but all of them are probably debian based. menuentry "Linux Mint 10 Gnome ISO" { loopback loop /linuxmint10.iso linux (loop)/casper/vmlinuz file=/cdrom/preseed/mint.seed boot=casper initrd=/casper/initrd.lz iso-scan/filename=/linuxmint10.iso noeject noprompt splash -- initrd (loop)/casper/initrd.lz } menuentry "DBAN ISO" { loopback loop /dban.iso linux (loop)/DBAN.BZI nuke="dwipe" iso-scan/filename=/dban.iso silent -- } menuentry "Tinycore ISO" { loopback loop /tinycore.iso linux (loop)/boot/bzImage -- initrd (loop)/boot/tinycore.gz } menuentry "SystemRescueCd" { loopback loop /systemrescuecd.iso linux (loop)/isolinux/rescuecd isoloop=/systemrescuecd.iso setkmap=us docache dostartx initrd (loop)/isolinux/initram.igz } Edit2: How to chainload grub and syslinux from grub2? Edit3: I want to boot other live images without any removable devices and use grub2 so need menu entries specific to grub2.

    Read the article

  • Unable to install Hadoop in Ubuntu 12.04

    - by Anitha
    I am trying to install hadoop in ubuntu 12.04 version. Following the instructions from michael-noll.com/tutorials/running-hadoop-on-ubuntu-linux-single-node-cluster/. Installed java-6-openjdk from ubuntu software center. I have set java_home in .bashrc.Also set java_home in hadoop conf/ env.sh. While formatting the namenode, getting error: usr/lib/jvm/java-6-openjdk/bin/java no such file or directory.

    Read the article

  • I receive the error 'grub-install /dev/sda failed' while attempting to install Ubuntu as the computer's only OS.

    - by Liath
    I am attempting to install Ubuntu on a box which was previously running Windows 7. I have also experienced the dreaded "Unable to install GRUB" error. I am not attempting to dual boot. I have previously run a Windows boot disk and removed all existing partitions. If I run the Ubuntu 12.04 install CD and click install after the config screens, I get the error Executing 'grub-install /dev/sda' failed. This is a fatal error. (It is the same error as this question: Unable to install GRUB) All the questions I've read while looking for a solution are related to dual boot. I'm not interested in dual boot, I'm after a clean out the box Ubuntu install. How can I achieve this? (For my sanity, please use very simple instructions when responding. I don't claim to have any talent either for linux or as a sysadmin) Additional details copied from comments dated: 2012-05-29 ~15:19Z After booting from the CD, clicking Try Ubuntu, and then sudo fdisk /dev/sda I get fdisk: unable to seek on /dev/sda: Invalid argument sudo fdisk /dev/sdb gives Device contains neither a valid DOS partiion table, nor Sun, SGI or OSF disklabel. Building a new DOS disklabel with disk identifier 0x15228d1d. Changes will remain in memory only until you decide to write them. After that of course, the previous content won't be recoverable. Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite). Command (m for help): I should add the Live CD desktop is graphically bad. I've got missing parts of programs and the terminal occasionally reflects to the bottom of the screen. But I can't imagine this is related.

    Read the article

  • My fresh installed ubuntu 12,4 won´t start without live usb drive

    - by Alexander Neira
    I just installed a fresh copy of ubuntu 12,04 in my netbook, through a live USB drive. I used the whole HDD and erased an existent win 7 partition. It installed everything and then asked me to reboot. When I did that, after rebooting, it only appeared the writer marker on top of a black screen and only that. Then, i plugged in again my usb drive and reboot. It loaded, but in the loading screen sent me (once) an error about the hard drive, that some file was missing (sorry i coulnd't write down the exact message). After that, I tried to re install ubuntu using my USB drive, but it sends me inmediately to the login screen. How do I solve this?

    Read the article

  • what is the file: C:\nppdf32Log\debuglog.txt

    - by Jesse
    Hello Everyone After I updated to 12.04, a file named " C:\nppdf32Log\debuglog.txt" occurs in my home directory, the content of the file is as the follow: NPP_Initialize : called NPP_GetValue is called NPP_SetWindow : called for instance 920c0e28 Window from browser - 77594625 NPP_SetWindow : called for instance 920c0e28 Window from browser - 77594625 NPP_SetWindow : called for instance 920c0e28 Window from browser - 77594625 NPP_NewStream : called for instance 920c0e28, stream 913403b0, URL http://www.xxxxxx.com/attachments/soft/CDGM%20Optical%20Glass%20Catalog.pdf, stream size 36177984, seekable 1 NPP_Write : called for instance 920c0e28, stream 913403b0, offset = 0, length = 16384, streamlength = 36177984 Trying for window attributes Trying for query tree NPP_Write : called for instance 920c0e28, stream 913403b0, offset = 16384, length = 16384, streamlength = 36177984 Trying for window attributes Trying for query tree ...... It seems this file is related to FireFox,what's exactly the problem? many thanks for your help!

    Read the article

  • How to let maas' cloud-init client select internal mirror?

    - by Michael
    Our maas lan can't access internet and have a internal apt-mirror site 192.168.3.6. I changed mirror set of maas server's snippets/maas_proxy file like: d-i mirror/country string manual d-i mirror/http/hostname string 192.168.3.6 d-i mirror/http/directory string /ubuntu d-i mirror/http/proxy string I deployed two maas node ok. Dashboard show the two node's state are ready. But node's cloud-init client changed the apt's sources.list like this: ## Note, this file is written by cloud-init on first boot of an instance ## modifications made here will not survive a re-bundle. ## if you wish to make changes you can: ## a.) add 'apt_preserve_sources_list: true' to /etc/cloud/cloud.cfg ## or do the same in user-data ... deb http://archive.ubuntu.com/ubuntu precise main deb-src http://archive.ubuntu.com/ubuntu precise main ... Directly use cobbler install node(without maas), the node apt's sources.list like: ... deb http://192.168.3.6/ubuntu precise main deb-src http://192.168.3.6/ubuntu precise main ... My question is: How to set user-data in maas? So that I can set cloud-init's mirror's url to 192.168.3.6 or prevent cloud-init to change mirror's url. Maas node's file /home/ubuntu/.ssh/authorized_keys is empty. Is it caused by the mirror's setup?

    Read the article

  • Change spacing of icons in Indicator Applet Complete, preferably by editing a config file?

    - by PeaTearGriffin
    Changing icon spacing within Application Indicator Complete. If at all possible, I'd like to space them with about 1-3px between each one. https://launchpad.net/indicator-applet [Website] I'm using 12.04, and in GNOME Classic (No Effects). I'm working from a netbook (1024x600), and am trying to fit everything into one panel for the sake of screen conservation. Ironically, my netbook is often without reliable net access, and so a way to simply edit a config file or the like would be ideal, as opposed to downloading patches, modified packages, etc., but anything would be helpful. Even pointing me in the direction of how to start rebuilding the indicator to meet my needs (if need-be) would be welcome. Does anyone know of a method that would serve my purpose? EDIT: I've downloaded v0.4.93 from the site mentioned above, and took a look inside the archive. Couldn't find anything clearly alluding to object placement/size and such. Maybe just a pointer on where to find those params would do? EDIT 2: Some more info on my WM/DE: I'm pretty sure GNOME classic is gtk2 not gtk3, and equally sure my windows manager is metacity, as opposed to compiz. "equally sure" meaning i could be horribly wrong, but when I edit the metacity css file for my theme (which ive switched to "Adawaita"), it takes effect after logout/login. My inability to modify the spacing persists. Im gonna see if i can contact someone involved in its dev to get their input, will post results here if fruitful.

    Read the article

  • MAAS not working

    - by Zimika
    I'm trying a whole week to make MASS to work, but no results. This is the procedure: maas createsuperuser sudo apt-get install maas-dhcp maas-import-isos apt-get install maas-enlist tftpd-hpa maas-import-isos After this I start node machine with PXE as default first boot device, and select option maas-enlist. Sistem start to installing some things, and after that on MAAS WebUI stand 1 node. But when I click on Node button on WebUI or refresh page, it show 0 node. Command cobbler system list showing: root@maas-serv:~# cobbler system list default node-3ee116ea-a8b2-11e1-a735-50e549e38206 Also, sometime this procedure register one node, but when registering second one, same problem like I described up. root@maas-serv:/var/lib/tftpboot/pxelinux.cfg# is empty, only default is there. On command maas-import-isos there is a one warning. ftpboot/images/precise-x86_64-maas-ephemeral/initrd copying images generating GPXE/PXE configuration files generating PXE menu structure warning: kernel option length exceeds 255 warning: kernel option length exceeds 255 warning: kernel option length exceeds 255 warning: kernel option length exceeds 255 copying files for distro: precise-x86_64

    Read the article

  • Ubuntu 12.04 upgrade and thunderbird

    - by Dcm1405
    After applying the suggested updates (179) an error message at the very end of the process suggested me to run apt-get install -f. Since it is a fairly new Ubuntu install (x86) I didn't setup anything in Thunderbird yet. Different error messages (see details) were generated with the -f process: ~$ sudo apt-get install -f Reading package lists... Done Building dependency tree Reading state information... Done Correcting dependencies... Done The following extra packages will be installed: thunderbird Suggested packages: latex-xft-fonts The following packages will be upgraded: thunderbird 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 2 not fully installed or removed. Need to get 0 B/20.8 MB of archives. After this operation, 594 kB of additional disk space will be used. Do you want to continue [Y/n]? y (Reading database ... 170457 files and directories currently installed.) Preparing to replace thunderbird 11.0.1+build1-0ubuntu2 (using .../thunderbird_12.0.1+build1-0ubuntu0.12.04.1_i386.deb) ... Unpacking replacement thunderbird ... dpkg-deb (subprocess): data: internal gzip read error: '<fd:4>: invalid code lengths set' dpkg-deb: error: subprocess <decompress> returned error exit status 2 dpkg: error processing /var/cache/apt/archives /thunderbird_12.0.1+build1-0ubuntu0.12.04.1_i386.deb (--unpack): short read on buffer copy for backend dpkg-deb during `./usr/lib/thunderbird/libxul.so' Errors were encountered while processing: /var/cache/apt/archives/thunderbird_12.0.1+build1-0ubuntu0.12.04.1_i386.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

    Read the article

  • Ubuntu 11.10 USB 3.0 HDD

    - by Chazm
    I have a problem with my external HDD (WD My Book Essential 1TB) working on USB 3.0 port. I'm using dual boot setup with Windows 7 and Ubuntu 11.10, both 64 bit. While I'm running Windows and rebooting back to Windows everything works well. When I'm switchin to ubuntu everything works great as well. But after 1st reboot from ubuntu neither windows nor ubuntu mount the external drive. I have to reboot the device manually. I suspect that the problem is with unmounting the device on shutdown on ubuntu. The case concern only usb 3.0. When i plug the same device into usb 2 port the problem doesn't persist. Does any1 hit the same problem or have a clue what might goin wrong?

    Read the article

  • USB modeswitch to mass storage device

    - by Andrew
    I'm trying to install a Sierra AirCard 320U (branded as "Telstra USB 4G") into a VirtualBox Windows XP machine, on an Ubuntu 10.10 host. usb_modeswitch offers me a way to disable the "mass storage device" option, but I can't see a way to permanently re-enable it so it's usable by VirtualBox (device filters briefly detect it but then it disappears again). lsusb shows the device as: 0f3d:68aa Airprime, Incorporated When I first insert the device, it shows as 1199:0fff Sierra Wireless, Inc. Is there any way to re-enable the storage device so VirtualBox can see it?

    Read the article

  • SPSS launcher for Unity

    - by user67157
    I have "SPSS 20 for Linux" statistical analysis program installed under /opt/IBM directory. I can run it via terminal entering the command line with /opt/IBM, and it runs without any problems. When the program window opens, I go to the launcher and right-click on its icon to lock it there, but after closing it, the icon becomes useless. When I click on it, nothing happens. I tried to ceate a launcher for it, but there is no use again.

    Read the article

  • Weird keyboard problem

    - by Sebastian
    I just installed Ubuntu on an Acer Extensa 5620 laptop. The keyboard works fine except when I want to type things that require me to use Ctrl+Alt+(any key). I can't use Ctrl+Alt+(any key) shortcuts in any program, but I can open terminal with Ctrl+Alt+T. Ctrl+(any key) and Alt+(any key) shortcuts seems to work though. Also I just installed the game Heroes of Newerth and neither Alt or Ctrl keys seem to work in the game. Any answer would be appreciated!

    Read the article

  • Ubuntu One Sync as a File Backup Solution?

    - by Jeff
    I was hoping to utilize Ubuntu One and in particular, the syncing feature within Ubuntu One to provide offsite backup for some of my files. My intention was to mark any of my folders that have important files as 'folders to synchronize' to Ubuntu One. It works great in that whenever an important file is placed in the folder, the file is copied up to Ubuntu One (hence creating a backup). However, if any of these important files are lost or accidently deleted from my computer then due to the synchronization it is also immediately deleted from Ubuntu One. This approach does not work very well to provide backup. On one hand I really like the automatic way in which the synch feature will upload any of my important files to Ubuntu One but on the other hand if I lose the file on my computer it will likely be taken off of the cloud as well (via synchronization). What approach are others taking to backup their important files to Ubuntu One? I didn't want to have to manually upload my important files to Ubuntu One and remember to upload other important files as they are created on my computer. Your thoughts and suggestions are greatly appreciated.

    Read the article

  • Apache on Windows - splitting vHost logs

    - by Cylindric
    I have a Windows Server 2008 running Apache, and it will be hosting several virtual hosts. I'd rather not use the logrotate tool (|bin/logrotate), as it seems create significant extra overhead with all the processes. Is there a simple Windows alternative to get the log entries from a combined log file split into several per-site files? Preferably with custom output directories, but that is optional.

    Read the article

  • Managing multiple reverse proxies for one virtual host in apache2

    - by Chris Betti
    I have many reverse proxies defined for my js-host VirtualHost, like so: /etc/apache2/sites-available/js-host <VirtualHost *:80> ServerName js-host.example.com [...] ProxyPreserveHost On ProxyPass /serviceA http://192.168.100.50/ ProxyPassReverse /serviceA http://192.168.100.50/ ProxyPass /serviceB http://192.168.100.51/ ProxyPassReverse /serviceB http://192.168.100.51/ [...] ProxyPass /serviceZ http://192.168.100.75/ ProxyPassReverse /serviceZ http://192.168.100.75/ </VirtualHost> The js-host site is acting as shared config for all of the reverse proxies. This works, but managing the proxies involves edits to the shared config, and an apache2 restart. Is there a way to manage individual proxies with a2ensite and a2dissite (or a better alternative)? My main objective is to isolate each proxy config as a separate file, and manage it via commands. First Attempt I tried making separate files with their own VirtualHost entries for each service: /etc/apache2/sites-available/js-host-serviceA <VirtualHost *:80> ServerName js-host.example.com [...] ProxyPass /serviceA http://192.168.100.50/ ProxyPassReverse /serviceA http://192.168.100.50/ </VirtualHost> /etc/apache2/sites-available/js-host-serviceB <VirtualHost *:80> ServerName js-host.example.com [...] ProxyPass /serviceB http://192.168.100.51/ ProxyPassReverse /serviceB http://192.168.100.51/ </VirtualHost> The problem with this is apache2 loads the first VirtualHost for a particular ServerName, and ignores the rest. They aren't "merged" somehow as I'd hoped.

    Read the article

  • How to shoot a triangle out of an asteroid which floats all of the way up to the screen?

    - by Holland
    I currently have an asteroid texture loaded as my "test player" for the game I'm writing. What I'm trying to figure out how to do is get a triangle to shoot from the center of the asteroid, and keep going until it hits the top of the screen. What happens in my case (as you'll see from the code I've posted), is that the triangle will show, however it will either be a long line, or it will just be a single triangle which stays in the same location as the asteroid moving around (that disappears when I stop pressing the space bar), or it simply won't appear at all. I've tried many different methods, but I could use a formula here. All I'm trying to do is write a space invaders clone for my final in C#. I know how to code fairly well, my formulas just need work is all. So far, this is what I have: Main Logic Code protected override void Draw(GameTime gameTime) { GraphicsDevice.Clear(ClearOptions.Target, Color.Black, 1, 1); mAsteroid.Draw(mSpriteBatch); if (mIsFired) { mPositions.Add(mAsteroid.LastPosition); mRay.Fire(mPositions); mIsFired = false; mRay.Bullets.Clear(); mPositions.Clear(); } base.Draw(gameTime); } Draw Code public void Draw() { VertexPositionColor[] vertices = new VertexPositionColor[3]; int stopDrawing = mGraphicsDevice.Viewport.Width / mGraphicsDevice.Viewport.Height; for (int i = 0; i < mRayPos.Length(); ++i) { vertices[0].Position = new Vector3(mRayPos.X, mRayPos.Y + 5f, 10); vertices[0].Color = Color.Blue; vertices[1].Position = new Vector3(mRayPos.X - 5f, mRayPos.Y - 5f, 10); vertices[1].Color = Color.White; vertices[2].Position = new Vector3(mRayPos.X + 5f, mRayPos.Y - 5f, 10); vertices[2].Color = Color.Red; mShader.CurrentTechnique.Passes[0].Apply(); mGraphicsDevice.DrawUserPrimitives<VertexPositionColor>(PrimitiveType.TriangleStrip, vertices, 0, 1); mRayPos += new Vector2(0, 1f); mGraphicsDevice.ReferenceStencil = 1; } }

    Read the article

  • Strategy to prevent players from seeing through walls in an online FPS?

    - by geneotech
    Why do we still moan on wallhackers in multiplayer first-person shooters ? Isn't it possible to perform occlusion culling for all players server-side ? For example, send player xyz information to client only when the player is visible in client's frustum and not occluded by any object ? Even if the collision-geometry is very simplified, most of the time cheater won't receive tactical information. Why not do this ?

    Read the article

  • Position sprite at center of screen

    - by Wellie
    I am trying to get a sprite to position itself at the center of the screen but nothing seems to be working for me. I'm trying Viewport viewport = graphics.GraphicsDevice.Viewport; logoPosition = new Vector2((viewport.Width - towerImage.Width) / 2, (viewport.Height - towerImage.Height) / 2); and spriteBatch.Draw(towerImage, centre, null, Color.White, 0, baseOrigin, 1.0f, SpriteEffects.None, 0); This is my first time using XNA and I don't really have a clue what I'm doing.

    Read the article

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